Summarize P6 benchmark, package it, write results, review proofs

- Benchmark summary: scripts/36_bench_verdicts.py applies the locked
  protocol_bench statements as worded (9/11 pass; S2-H1 fails for rock
  physics and wavelet phase), outside the lock hash.
- S7 packaging: scripts/37_bench_package.py, benchmark/ (manifest,
  reference tables, README, draft Zenodo metadata). Deposit not done.
- Paper: Experiment 3 (Sec. 6.5), T2 mechanism (Sec. 6.4), benchmark
  figures (scripts/38_bench_figures.py), dataset citations.
- Proof review of Sec. 4 and App. A (14 of 15 findings fixed, 1 partly;
  no verdict or reported number changed); docs/theory.md synced.
- Reproduction package: scripts/39_repro_package.py and repro/
  (manifest, README, clean-room verify report: 12/12 stages pass).
- Related work: preliminary novelty scan; full texts of AWSM, BootNet,
  Li et al. 2024, Guillon et al. 2020, Rizzuti et al. 2024/2025 and
  Castagna et al. 2026 checked; abstract-only markers updated and the
  Castagna sentence corrected. Paper compiles cleanly (68 pages).
- Docs synced (AGENTS.md, plan.md, report.html, READMEs).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-02 07:12:58 +00:00
parent 2e4f618947
commit 423a333ae9
40 changed files with 82893 additions and 170 deletions

View File

@@ -4,7 +4,7 @@ Seismic-to-porosity learning on F3 when the well tie is uncertain (RML: training
Read first: `docs/plan.md` (plan, gates, decisions; §6 roadmap, §10 forbidden claims, §12 decision log), `README.md` (setup, scripts, logging), `docs/theory.md`. Progress page: `report.html`. These docs are in Vietnamese. Read first: `docs/plan.md` (plan, gates, decisions; §6 roadmap, §10 forbidden claims, §12 decision log), `README.md` (setup, scripts, logging), `docs/theory.md`. Progress page: `report.html`. These docs are in Vietnamese.
## Status (29/10/2026) ## Status (02/11/2026)
- P0, P1 done. P2 closed: gate G-B failed on 26/10 and the P2 verdict stands. - P0, P1 done. P2 closed: gate G-B failed on 26/10 and the P2 verdict stands.
- **P2r** (P2 rerun on new realizations 8–15 under the new pre-registration `configs/protocol_p2r.yaml`) is done and committed (5a6fb2f). Summary in `outputs/p2r/summary/` (`verdict.json`, `summary.md`); details in `docs/plan.md` §12 items 11–14. - **P2r** (P2 rerun on new realizations 8–15 under the new pre-registration `configs/protocol_p2r.yaml`) is done and committed (5a6fb2f). Summary in `outputs/p2r/summary/` (`verdict.json`, `summary.md`); details in `docs/plan.md` §12 items 11–14.
@@ -81,8 +81,8 @@ Read first: `docs/plan.md` (plan, gates, decisions; §6 roadmap, §10 forbidden
Propositions 3–6 (classical/Berkson tie error, calibrated bank with a Propositions 3–6 (classical/Berkson tie error, calibrated bank with a
fourth-order population gain, coverage, misregistered reference), fourth-order population gain, coverage, misregistered reference),
Corollaries 3–4, T4 (`scripts/30_t4_coverage.py`) and the post hoc H2b Corollaries 3–4, T4 (`scripts/30_t4_coverage.py`) and the post hoc H2b
bound check (`scripts/31_p2r_posthoc.py`) in Sec. 6.3, T3 in Sec. 6.5, bound check (`scripts/31_p2r_posthoc.py`) in Sec. 6.3, T3 in Sec. 6.5 (6.6 since 02/11),
field cases in Sec. 6.6 with F3/Volve details moved to Appendix B. Red field cases in Sec. 6.6 (6.7 since 02/11) with F3/Volve details moved to Appendix B. Red
TODOs remain for S1–S8, T2 and the authors' declarations. **Self-correction TODOs remain for S1–S8, T2 and the authors' declarations. **Self-correction
(29/10, A6):** two earlier agent claims were wrong. The first was "the two (29/10, A6):** two earlier agent claims were wrong. The first was "the two
error structures give nearly the same bound (factor < 1.17)". In fact the error structures give nearly the same bound (factor < 1.17)". In fact the
@@ -95,7 +95,7 @@ Read first: `docs/plan.md` (plan, gates, decisions; §6 roadmap, §10 forbidden
computes both bounds and reads the Oracle npz files (about 6 min). The paper computes both bounds and reads the Oracle npz files (about 6 min). The paper
(Sec. 4.3, 6.3 with a 1/B_b column in `tab:h2b`, 6.4, 7, abstract, (Sec. 4.3, 6.3 with a 1/B_b column in `tab:h2b`, 6.4, 7, abstract,
introduction, conclusion) and the docs were corrected. **Length risk:** introduction, conclusion) and the docs were corrected. **Length risk:**
the main text is about 14,750 words (crude count after A6) against a Computers & Geosciences limit the main text was about 14,750 words (crude count after A6; about 18,100 after the 02/11 results pass) against a Computers & Geosciences limit
of about 5,500 (secondary source; not yet checked on the official page). of about 5,500 (secondary source; not yet checked on the official page).
The user dropped the length pass for the venue on 29/10/2026 (`docs/plan.md` The user dropped the length pass for the venue on 29/10/2026 (`docs/plan.md`
§12 item 25); the risk stays recorded as R9 with no mitigation. §12 item 25); the risk stays recorded as R9 with no mitigation.
@@ -109,7 +109,14 @@ Read first: `docs/plan.md` (plan, gates, decisions; §6 roadmap, §10 forbidden
- **P6 (level-B benchmark) started early on 29/10/2026; all main runs finished 02:16 UTC 30/10/2026** (`docs/plan.md` §12 item 26; code in commit 381b5ff). Subagents: Fable for reasoning-heavy work, Opus for routine work. - **P6 (level-B benchmark) started early on 29/10/2026; all main runs finished 02:16 UTC 30/10/2026** (`docs/plan.md` §12 item 26; code in commit 381b5ff). 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). - 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. - 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. **Final state (30/10):** S2 (224 posterior + 224 train) done 00:12 UTC, S3+S4+S8 train (384) done 00:58, S1 (560 train cells; posteriors done earlier) done 02:16 after a 01:02 split of group B into `p6_s1b_r0h` and `p6_s1b_r10tb` (36 workers, CPU-bound). The supervisor was stopped at 02:16; no P6 job is running and nothing needs resuming. Next P6 step: `scripts/34_run_bench.py summarize` (not run yet), then S7 packaging and the results rewrite. - 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. **Final state (30/10):** S2 (224 posterior + 224 train) done 00:12 UTC, S3+S4+S8 train (384) done 00:58, S1 (560 train cells; posteriors done earlier) done 02:16 after a 01:02 split of group B into `p6_s1b_r0h` and `p6_s1b_r10tb` (36 workers, CPU-bound). The supervisor was stopped at 02:16; no P6 job is running and nothing needs resuming.
- **Summarize done (02/11/2026, 02:02 UTC; `docs/plan.md` §12 item 28).** Lock and the 8,799 synced `outputs/bench/` files checked first. Locked `scripts/34_run_bench.py summarize` → `outputs/bench/summary/` (`verdict.json`, `summary.md`, csv tables). Its verdict extraction differs from the locked statements in three places (S1-H1 needs exactly 2 rows but S1 has 4 N values → null; S2-H1 has no top-level `pass` → "not available"; S3-H1 adds the disclosed Ctl-GP to the stated competitor set). Locked code was not edited: `scripts/36_bench_verdicts.py` (outside the lock hash; checks the lock first) applies the statements as worded → `verdict_final.json`, `verdict_final.md`, `s3_h2a_stated.csv`. Report both readings; the paper's Methods must disclose this implementation deviation.
- **Verdicts (as worded): 9/11 pass.** S1-H1 pass (R10 c = 1.5: 0.853 / 0.796 at N = 4/16); S1-H2 pass (13/13 wide families, ρ = −0.47, p < 1e−4); **S2-H1 fails for rock physics (0.940 / 0.934) and wavelet (1.023 / 1.042; posterior overconfident, cov90 0.17 / 0.10), passes for drift (0.862 / 0.798)**; S2-H2 pass (14/14 ≤ 1.02); S3-H1 pass in R10, R0, Rm5 (as run with Ctl-GP: fail everywhere, because Ctl-GP nearly equals B3d-Sa); S4-H1, S4-H2, S8-H1, S8-H2 pass. S2 is complete, so the paper may say "benchmark"; never claim H2a is robust to misspecification in general (`docs/plan.md` §10).
- **S7 packaging done (02/11/2026; `docs/plan.md` §12 item 29), except the Zenodo deposit.** `scripts/37_bench_package.py` (outside the lock; `generate`/`tables` check it first): `generate` → 630 tasks (test 8–15, dev 900–905; 45 per realization: 5 nominal regimes × 5 c, 14 S2 settings, 6 S8 settings), hidden truth, inputs and `inputs/analyst.json` in `outputs/bench/package/` (845 MB, gitignored, the Zenodo payload); content hashes in `benchmark/MANIFEST.json` (git). A second `generate` reproduced all 1,260 content hashes, and `check` matches 1,265/1,265 files (with the 5 inputs). `tables` → 45,200 reference runs (21 methods), `benchmark/reference/{cells.csv,main_table.md}`. `score --pred DIR --name NAME` applies the locked H2a cell rule and `better` rule of `summary.py`. `selftest` passes (copies of saved B3d-Sa/BK2 predictions reproduce metrics to 5e-10 and the rule outputs, e.g. S1-H1 0.8529 / 0.7964). User docs: `benchmark/README.md` (English); `benchmark/zenodo_metadata.json` is a draft. **Do not upload to Zenodo without the user**: it needs their account, the author list, and a check of the licence (draft CC BY-SA 3.0, inherited from F3).
- **Results sections written (02/11/2026; `docs/plan.md` §12 item 30).** The paper now has Sec. 6.5 "Experiment 3: registration-aware benchmark": design and verdict tables, with both readings of D-13; S1 phase diagram; S2 table with the rock-physics and wavelet-phase failures; S3; S4; S8 table and figure; equal budgets. Sec. 6.4 (T2) replaces its todoblock. Sec. 3.2 gains the misspecification presets, Sec. 5 the TCN and the benchmark rows of `tab:methods`. The abstract, introduction, discussion and conclusion were updated, and the title todo was removed. F3 and Volve dataset citations (`dgb2023f3demo`, `equinor2018volve`) are in `paper/refs.bib`. Figures come from `scripts/38_bench_figures.py` (outside the lock); `--flipband` prints the post hoc S8 cos/cos² table. The locked S8-H2 statement calls BK2 "calibrated" only in the weak sense that the truth is a member. Under Corollary 3 (a), its λ → 0 transfer is cos²(πfΔ), while the measured value is 0.92–1.00 at N = 16. The paper says so; the verdict is unchanged. The paper compiles cleanly (66 pages); the main text is about 18,100 words (R9, no mitigation). Remaining todos: authors, author declarations, repository URL and DOI, Zenodo DOI and licence, Teapot licence, the Sec. 2 novelty todoblock.
- **Preliminary novelty scan for the Sec. 2 todoblock (02/11/2026; `docs/plan.md` §12 item 31).** Crossref, OpenAlex 2025–2026 and web search found no work that feeds tie uncertainty into the training of a property predictor, so "To our knowledge…" stands. Added, abstract only: Herrera & van der Baan 2014 (Geophysics; the 2012 preprint stays the version read), Autotie (da Costa Silva et al., Geophysics 2026; new row entry in `tab:positioning`) and Castagna, Kronberg & Gil (TLE 2026, tie and prediction quality metrics). Sukar et al. 2026 was rechecked in full (`refs/`): it trains on simulator-derived synthetic 4D maps, so "UQ→train = --" is fair, and Sec. 2 now says no tie places its labels. Still open for the submission-day rerun (13/11): the Palavicini Gurria et al. IMAGE 2026 abstract (no IMAGE 2026 expanded abstract indexed yet) and the Quesada 2024 DOI (otherwise keep the lab URL). The todoblock was shortened to these items. The paper compiles cleanly (66 pages).
- **Proof review and reproduction package (02/11/2026; `docs/plan.md` §12 item 32).** An independent subagent read Sec. 4, App. A and Lemma 5 and returned 15 findings; 14 were fixed and 1 partly (the registered names $B_a$/$B_b$ stay). No verdict or reported number changed. Main fixes: (A2) needs a bounded second moment; (B) is restricted to integer shifts up to β_max; Corollary 3's equal-weight two-member bank contains the true warp but is not calibrated, and cos²(πfΔ) is its λ → 0 transfer; Corollary 4's σ_r < σ/√2 is necessary at every frequency but not sufficient, and Sec. 6.6 now gives the simulated crossings 3.6/3.8/4.3 ms against σ/√2 = 3.0/4.1/5.1 ms; `docs/theory.md` synced. `scripts/39_repro_package.py` (outside every lock) builds five deterministic derived-data archives in `outputs/repro/` (gitignored; 11,112 files; F3 and synthetic CC BY-SA 3.0, Volve CC BY-NC-SA 4.0, Teapot CC0 unverified) with `repro/MANIFEST.json` (git), and `verify` reruns 12 stages in a clean room without raw data. The run of 02/11 (20 min, CPU) passes: 12/12 stages exit 0, no reads outside the clean room, 63 rewritten files identical in bytes (the 8 figures pixel-identical), 3 equal in value, none different; `tests/test_d2_misspec.py` passes 15/15 there (`repro/verify_report.md`). Reader docs: `repro/README.md`, `repro/requirements-linux.txt`; Sec. 8 has a derived-data sentence (DOI todo). **Not done, needs the user:** the deposit, the licence choice for the combined F3+Volve applicability tables, a code licence, and `39 code --rev` after a commit. The paper compiled cleanly then (67 pages).
- **Full texts of six abstract-only references (02/11/2026; `docs/plan.md` §12 item 33).** The user downloaded AWSM (`lim2025awsm`), BootNet (`lim2025bootnet`), P05 (`li2024bpinn`) and Guillon et al. 2020 (`guillon2020gtmetrics`) into `refs/`, renamed to their BibTeX keys; the two Rizzuti papers were obtained earlier that day. Every claim in Sec. 2 was checked against the full texts. The table classifications and "To our knowledge…" are unchanged. AWSM reports a time–depth posterior for 44 wells but keeps only the median- and minimum-misfit models, and no later step uses the posterior. Their ᵃ markers were removed, Sec. 2 now uses full-text wording, and the `refs.bib` annotes were updated. The paper compiles cleanly (68 pages). Still abstract-only: Autotie, Herrera 2014, Thiebaud, Cordoba, Mirza, Quesada, Huff, P04, P07, P09. **Closed by the user (02/11/2026):** no further full-text search; those entries keep their ᵃ marker. Castagna 2026 (CC BY) was then downloaded by the user (`refs/castagna2026quality.pdf`) and read in full. Its Discussion does address timing error: time–depth functions are never exact, time shifts mainly degrade the high frequencies, and their distribution-based measures are insensitive to small shifts. It does not model that error or use it in training. The earlier Sec. 2 sentence ("Their abstract does not consider error in the timing…") was therefore replaced; "To our knowledge…" stands.
- **Server move (30/10):** the repository folder is synced as a whole to a new server; `outputs/` stays out of git. About 600 MB of outputs force-added and pushed at 01:05–01:15 UTC were removed by a history rewrite and force-push at the user's request (`main` = 381b5ff). What is not in git, with sha256: `docs/research/server-migration.md`, `docs/research/unpushed_outputs.sha256`. tmux sessions do not move with the folder. - **Server move (30/10):** the repository folder is synced as a whole to a new server; `outputs/` stays out of git. About 600 MB of outputs force-added and pushed at 01:05–01:15 UTC were removed by a history rewrite and force-push at the user's request (`main` = 381b5ff). What is not in git, with sha256: `docs/research/server-migration.md`, `docs/research/unpushed_outputs.sha256`. tmux sessions do not move with the folder.
- 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). - 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).
@@ -118,21 +125,20 @@ Read first: `docs/plan.md` (plan, gates, decisions; §6 roadmap, §10 forbidden
Schedule: `docs/plan.md` §6.1 (level B, 29/10 → 14/11/2026). Cut-scope order Schedule: `docs/plan.md` §6.1 (level B, 29/10 → 14/11/2026). Cut-scope order
if late is given there; never cut thresholds. if late is given there; never cut thresholds.
1. **Dataset citations (30–31/10).** Level A writing is done (plan §12 item 24). 1. **Dataset citations: done 02/11/2026** (plan §12 item 30). The length pass
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 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. not schedule it.
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`. 2. **T2 mechanism study: done on 29/10/2026; written into Sec. 6.4 on 02/11/2026** (plan §12 item 30).
3. **protocol_bench: done early (locked 29/10 14:39 UTC).** See Status. 3. **protocol_bench: done early (locked 29/10 14:39 UTC).** See Status.
4. **Runs: done early (29/10 14:43 → 30/10 02:16 UTC).** Next: run 4. **Runs: done early (29/10 14:43 → 30/10 02:16 UTC). Summarize and the 11
`scripts/34_run_bench.py summarize` on the new server (needs only files verdicts: done 02/11/2026** (see Status; `outputs/bench/summary/verdict_final.md`).
in the synced folder), report the S1–S8 verdicts as they come out, 5. **S7 packaging: done 02/11/2026** except the Zenodo deposit (user's account; fill the TODOs of
including failures. `benchmark/zenodo_metadata.json` first, then put the DOI into `benchmark/README.md` and Sec. 8).
5. **S7 packaging (8–10/11):** one command to generate, one to score, reference **Results sections: done 02/11/2026** (plan §12 item 30). **Proof appendix review and reproduction
tables, README, hashes, Zenodo deposit; then rewrite the results sections. package: done 02/11/2026** (plan §12 item 32) except the deposit of `outputs/repro/*.tar.gz` (user's account and licence decisions).
6. **Review and submission (11–14/11):** internal review, figures, proof 6. **Next: review and submission (11–14/11; can start early):** internal review, figures, final
appendix, final novelty scan, quartile check, preprint, submit to proofread of the proof appendix (reviewed 02/11), final novelty scan (Sec. 2 todoblock; preliminary scan done 02/11, plan §12 item 31), quartile check, preprint, submit to
*Computers & Geosciences*. *Computers & Geosciences*. The authors must fill the author list and declarations.
## Conventions ## Conventions

View File

@@ -10,6 +10,8 @@ python -m venv .venv
.venv/bin/pip install --no-deps -e . .venv/bin/pip install --no-deps -e .
``` ```
Môi trường Linux của các lock `protocol_volve`/`protocol_bench` (Python 3.13.15, torch 2.14.0+cu130, numpy 2.5.4): `repro/requirements-linux.txt`; `requirements-lock.txt` là môi trường P0 cũ (numpy 2.5.3). Môi trường của P3 trên Windows: `requirements-windows-rtx3060.txt`.
Dữ liệu F3 Demo 2023 đặt ở `data/F3_Demo_2023/F3_Demo_2023/`, dữ liệu Volve ở `data/Volve/`, LAS và TD của NLOG ở `data/NLOG/` (hoặc trỏ `ML_POROSITY_F3_ROOT` tới thư mục chứa `.survey`). Kết quả ghi vào `outputs/` (đổi bằng `ML_POROSITY_OUTPUTS`). Dữ liệu F3 Demo 2023 đặt ở `data/F3_Demo_2023/F3_Demo_2023/`, dữ liệu Volve ở `data/Volve/`, LAS và TD của NLOG ở `data/NLOG/` (hoặc trỏ `ML_POROSITY_F3_ROOT` tới thư mục chứa `.survey`). Kết quả ghi vào `outputs/` (đổi bằng `ML_POROSITY_OUTPUTS`).
Code luận văn được lưu ở [`code_thesis/`](code_thesis/), các output gốc ở [`outputs_thesis/`](outputs_thesis/). SHA-256 của 7 artifact nằm trong [`data_manifest/thesis_outputs.json`](data_manifest/thesis_outputs.json); kết quả kiểm tra ngày 27/10/2026 ở [thesis-output-audit.md](docs/research/thesis-output-audit.md). Pipeline nghiên cứu ghi kết quả mới vào `outputs/`. Code luận văn được lưu ở [`code_thesis/`](code_thesis/), các output gốc ở [`outputs_thesis/`](outputs_thesis/). SHA-256 của 7 artifact nằm trong [`data_manifest/thesis_outputs.json`](data_manifest/thesis_outputs.json); kết quả kiểm tra ngày 27/10/2026 ở [thesis-output-audit.md](docs/research/thesis-output-audit.md). Pipeline nghiên cứu ghi kết quả mới vào `outputs/`.
@@ -66,6 +68,11 @@ ARMS=sensitivity scripts/run_p4.sh register train # nhánh σ_a = 3,5 / 14 ms;
scripts/run_bench.sh lock # P6 protocol_bench: khoá lần đầu (sau khi duyệt bản nháp) scripts/run_bench.sh lock # P6 protocol_bench: khoá lần đầu (sau khi duyệt bản nháp)
STUDIES="S1" DEVICE=cuda:0 WORKERS=4 scripts/run_bench.sh posterior train # S1 trên cuda:0; các study khác tương tự (STUDIES, REGIMES, PRESETS, RIDS, DEV=1) STUDIES="S1" DEVICE=cuda:0 WORKERS=4 scripts/run_bench.sh posterior train # S1 trên cuda:0; các study khác tương tự (STUDIES, REGIMES, PRESETS, RIDS, DEV=1)
scripts/run_bench.sh summarize | status | repro # tổng hợp theo luật đã khai báo; tiến độ; ô tái lập P2r scripts/run_bench.sh summarize | status | repro # tổng hợp theo luật đã khai báo; tiến độ; ô tái lập P2r
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/36_bench_verdicts.py # sau summarize: verdict cuối theo đúng lời phát biểu → outputs/bench/summary/verdict_final.{json,md}
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py generate # S7: gói benchmark; sau đó lần lượt tables, selftest → outputs/bench/package/ (hash: benchmark/MANIFEST.json)
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py score --pred DIR --name TÊN # chấm một phương pháp theo luật protocol_bench (hướng dẫn: benchmark/README.md)
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/38_bench_figures.py [--only bench_s1,bench_s8] [--flipband] # hình Thí nghiệm 3 của bài → paper/figures/; --flipband in bảng cos/cos² của S8
CUDA_VISIBLE_DEVICES= OMP_NUM_THREADS=2 .venv/bin/python scripts/39_repro_package.py build | verify # P5 gói tái lập: archive dữ liệu dẫn xuất → outputs/repro/, manifest repro/MANIFEST.json; phòng sạch → repro/verify_report.md (hướng dẫn: repro/README.md)
# Run dài: chạy trong tmux server của người dùng, ví dụ tmux new-session -d -s p6_s2 -c $PWD "env STUDIES=S2 DEVICE=cuda:0 WORKERS=2 MEM_GB=2 scripts/run_bench.sh posterior train >> logs/bench_s2_cuda0.out 2>&1" # Run dài: chạy trong tmux server của người dùng, ví dụ tmux new-session -d -s p6_s2 -c $PWD "env STUDIES=S2 DEVICE=cuda:0 WORKERS=2 MEM_GB=2 scripts/run_bench.sh posterior train >> logs/bench_s2_cuda0.out 2>&1"
# (setsid nohup bị dừng khi phiên agent kết thúc, 29/10). operations/p6_s1_watcher.sh khởi động S1 khi GPU có chỗ trống (đã dùng 15:43–16:06 UTC 29/10, rồi bỏ khi GPU trống). # (setsid nohup bị dừng khi phiên agent kết thúc, 29/10). operations/p6_s1_watcher.sh khởi động S1 khi GPU có chỗ trống (đã dùng 15:43–16:06 UTC 29/10, rồi bỏ khi GPU trống).
# operations/p6_supervisor.py (tmux p6_supervisor): mỗi 5 phút chạy lại driver P6 chết và dồn worker khi một study xong; log logs/p6_supervisor.out. Đã dừng 02:16 UTC 30/10 khi P6 xong. Lỗi đã biết: khi dồn worker, nó khởi động lại driver kể cả lúc số worker không đổi, làm mất job đang dở. # operations/p6_supervisor.py (tmux p6_supervisor): mỗi 5 phút chạy lại driver P6 chết và dồn worker khi một study xong; log logs/p6_supervisor.out. Đã dừng 02:16 UTC 30/10 khi P6 xong. Lỗi đã biết: khi dồn worker, nó khởi động lại driver kể cả lúc số worker không đổi, làm mất job đang dở.
@@ -123,5 +130,9 @@ Biến môi trường máy đặt sẵn `OMP_NUM_THREADS=40` (cả MKL, OpenBLAS
| `scripts/33_bench_generator_qc.py` | QC bộ sinh cho S2 (P6, `p6-gen`; CPU, khoảng 1 phút): với realization dev 902 và từng preset misspec trong `configs/d2_synth_bench.yaml`, đo thay đổi AI thật, wavelet thật (pha hằng khớp nhất, tần số đỉnh, băng 90 %), warp thật (RMS, bước nhảy, jitter), sai số mô hình mà registration thấy tại warp thật (wavelet F3 danh nghĩa và thành viên tốt nhất trong họ wavelet thống kê + pha hằng, quy ra dB), tie chỉ anchor (Laplace, N = 4); `--sweep` quét từng núm đơn; `--smc --device cuda:1` (hoặc `cpu`) chạy registration + SMC tie posterior như P2r cho từng preset ở R10/Rm5, N = 4, nối tiếp ô đã xong → `outputs/bench/dev/{generator_qc.json, generator_qc.png, generator_sweep.json, smc_qc_rid902.json}`. Thiết kế: `docs/research/bench-generator.md` | | `scripts/33_bench_generator_qc.py` | QC bộ sinh cho S2 (P6, `p6-gen`; CPU, khoảng 1 phút): với realization dev 902 và từng preset misspec trong `configs/d2_synth_bench.yaml`, đo thay đổi AI thật, wavelet thật (pha hằng khớp nhất, tần số đỉnh, băng 90 %), warp thật (RMS, bước nhảy, jitter), sai số mô hình mà registration thấy tại warp thật (wavelet F3 danh nghĩa và thành viên tốt nhất trong họ wavelet thống kê + pha hằng, quy ra dB), tie chỉ anchor (Laplace, N = 4); `--sweep` quét từng núm đơn; `--smc --device cuda:1` (hoặc `cpu`) chạy registration + SMC tie posterior như P2r cho từng preset ở R10/Rm5, N = 4, nối tiếp ô đã xong → `outputs/bench/dev/{generator_qc.json, generator_qc.png, generator_sweep.json, smc_qc_rid902.json}`. Thiết kế: `docs/research/bench-generator.md` |
| `scripts/34_run_bench.py <stage…> [--studies S1 S2 S3 S4 S8] [--device] [--workers] [--gpu-mem-gb] [--dev --rids 902…]` | Runner của `configs/protocol_bench.yaml` (P6, mức B): `lock` (khoá: `.sha256` + `.lock.json` gồm code, môi trường, input, artifact P2r tham chiếu, fingerprint bộ sinh danh nghĩa), `posterior` (SMC như scripts/14, nhánh estR, P = 1024, lưu hạt γ = 1/κ), `train` (như scripts/15 + B4a–d, nhánh S8 hai mode, backbone TCN), `summarize` (luật đã khai báo trước → `outputs/bench/summary/`), `repro` (ô tái lập P2r → `outputs/bench/repro/comparison.json`), `dev-budgets` (ngân sách TCN trên dev). Realization 8–15 chỉ chạy sau khi khoá; `--dev` chỉ nhận 900–905 và ghi vào `outputs/bench/dev/`. Resume theo fingerprint + checksum. Mã: `ml_porosity/benchmark/` | | `scripts/34_run_bench.py <stage…> [--studies S1 S2 S3 S4 S8] [--device] [--workers] [--gpu-mem-gb] [--dev --rids 902…]` | Runner của `configs/protocol_bench.yaml` (P6, mức B): `lock` (khoá: `.sha256` + `.lock.json` gồm code, môi trường, input, artifact P2r tham chiếu, fingerprint bộ sinh danh nghĩa), `posterior` (SMC như scripts/14, nhánh estR, P = 1024, lưu hạt γ = 1/κ), `train` (như scripts/15 + B4a–d, nhánh S8 hai mode, backbone TCN), `summarize` (luật đã khai báo trước → `outputs/bench/summary/`), `repro` (ô tái lập P2r → `outputs/bench/repro/comparison.json`), `dev-budgets` (ngân sách TCN trên dev). Realization 8–15 chỉ chạy sau khi khoá; `--dev` chỉ nhận 900–905 và ghi vào `outputs/bench/dev/`. Resume theo fingerprint + checksum. Mã: `ml_porosity/benchmark/` |
| `scripts/35_bench_calibration.py [--rids 902 903 904 905]` | Bảng hiệu chuẩn mức S2 (dev): gộp `outputs/bench/dev/smc_qc_rid*.json` (scripts/33 `--smc`) thành `calibration.{csv,md}`: sai số mô hình trong họ so với nhiễu regime, SMC warp RMSE / coverage90 / σ_post / overconfidence, phase_R, B3c, theo preset × regime | | `scripts/35_bench_calibration.py [--rids 902 903 904 905]` | Bảng hiệu chuẩn mức S2 (dev): gộp `outputs/bench/dev/smc_qc_rid*.json` (scripts/33 `--smc`) thành `calibration.{csv,md}`: sai số mô hình trong họ so với nhiễu regime, SMC warp RMSE / coverage90 / σ_post / overconfidence, phase_R, B3c, theo preset × regime |
| `scripts/36_bench_verdicts.py` | Verdict cuối của protocol_bench (02/11/2026): kiểm lock (`freeze(check=True)`), đọc `verdict.json` của summarize và áp đúng lời phát biểu ở ba chỗ code đã khoá khác (S1-H1 lọc N ∈ {4, 16}; S2-H1 theo từng trục; S3-H1 đối thủ {B3b, B3c, B3c-R, B4a–d}, không có Ctl-GP) bằng chính hàm của `ml_porosity/benchmark/summary.py` → `outputs/bench/summary/{verdict_final.json,verdict_final.md,s3_h2a_stated.csv}`. Ngoài tập hash của lock; không sửa output của summarize (`docs/plan.md` §12 ý 28) |
| `scripts/37_bench_package.py <lệnh> [--out DIR]` (generate, check, tables, score, selftest) | S7 đóng gói benchmark (02/11/2026; ngoài lock, generate và tables kiểm lock trước): `generate` ghi 630 task (test 8–15, dev 900–905; 5 regime danh nghĩa × 5 c, 14 setting S2, 6 setting S8), truth ẩn, input và `inputs/analyst.json` vào `outputs/bench/package/` (khoảng 845 MB), rồi so sha256 nội dung với `benchmark/MANIFEST.json` (lần đầu thì ghi); `check` kiểm một bản tải về; `tables` gộp 45.200 run tham chiếu → `reference/runs.csv.gz`, `benchmark/reference/{cells.csv,main_table.md}`; `score --pred DIR --name TÊN` chấm dự đoán `r<rid>_c<c>_n<N>_s<seed>.npz` (metric của scripts/11, luật ô H2a và luật better của `summary.py`) → `DIR/score/`; `selftest` chép dự đoán tham chiếu đã lưu thành bài nộp và kiểm metric, truth và luật khớp. Hướng dẫn cho người dùng: `benchmark/README.md` |
| `scripts/38_bench_figures.py [--only bench_s1,bench_s8] [--flipband]` | Hình Thí nghiệm 3 của bài (02/11/2026; ngoài lock, kiểm lock trước, không ghi vào `outputs/`): `bench_s1` (phase diagram S1 từ `outputs/bench/summary/s1_cells.csv`) và `bench_s8` (hàm truyền hai mode từ `s8_transfer_curves.json`; băng dùng được tính lại từ file dự đoán S8 như `summary.py`) → `paper/figures/{bench_s1,bench_s8}.pdf`, cùng style với scripts/22. `--flipband` chỉ in ra stdout bảng post hoc của Sec. 6.5: trung bình cos(πfΔ), cos²(πfΔ) (Hệ quả 3) và transfer đo được của PM2/BK2/HM2 trong băng 1/(2Δ) < f < 3/(2Δ) (D-14) |
| `scripts/39_repro_package.py <lệnh> [--out DIR]` (build, check, verify, code) | P5 gói tái lập (02/11/2026; ngoài mọi lock, không train, không ghi vào `outputs/` gốc): `build` chọn file của `outputs/` theo `RULES` và ghi 5 archive tar.gz tất định theo giấy phép dữ liệu (f3_results, f3_predictions, f3_volume: CC BY-SA 3.0; volve: CC BY-NC-SA 4.0; teapot: CC0, cần kiểm) vào `outputs/repro/`, cùng `repro/MANIFEST.json` (11.112 file, sha256 từng file, script sinh ra); `check --root DIR` kiểm một cây đã giải nén; `verify [--only …] [--keep]` dựng phòng sạch (code + archive, không SEG-Y/Volve/Teapot thô), chạy lại 12 bước tổng hợp, post hoc, bảng và hình, theo dõi file mở bằng audit hook rồi so với bản gốc → `repro/verify_report.md` (02/11: 12/12 bước khớp, 63 file trùng byte, 3 trùng giá trị, 0 khác); `code --rev REV` ghi `git archive` của một commit. Hướng dẫn cho người đọc (tiếng Anh): `repro/README.md` |
`code_thesis/` là bản lưu trữ code luận văn. Giữ nguyên nội dung để đối chiếu: các script này còn đường dẫn máy cũ và ghi vào `outputs/`, nên cần một bản sao đã điều chỉnh đường dẫn nếu muốn chạy lại. Kiểm tra bộ artifact hiện có bằng `python scripts/00_data_manifest.py --dataset thesis --check`. `code_thesis/` là bản lưu trữ code luận văn. Giữ nguyên nội dung để đối chiếu: các script này còn đường dẫn máy cũ và ghi vào `outputs/`, nên cần một bản sao đã điều chỉnh đường dẫn nếu muốn chạy lại. Kiểm tra bộ artifact hiện có bằng `python scripts/00_data_manifest.py --dataset thesis --check`.

1296
benchmark/MANIFEST.json Normal file

File diff suppressed because it is too large Load Diff

192
benchmark/README.md Normal file
View File

@@ -0,0 +1,192 @@
# A registration-aware benchmark for sparse-well seismic porosity learning
Version 1 (protocol_bench, locked 29/10/2026 14:39 UTC, sha256 `aa763f0a…`). This directory documents the benchmark
package: synthetic seismic-to-porosity tasks in which the time–depth tie of every training well is uncertain and the
truth is known. The data package itself (about 630 tasks) is generated by one command and is deposited on Zenodo
(DOI: TODO).
## 1. The problem
A network learns porosity on seismic time from a few wells. Its labels come from logs recorded in depth (here: on
the sonic time τ of the log), so each label trace depends on a well tie t(τ) that is itself estimated from the
seismic and from a few marker picks. A tie error shifts the labels relative to the seismic. The benchmark asks how
much a learning method loses to this registration error, and whether a method that uses the uncertainty of the tie
does better than one that trains on a single point tie.
Each task is one synthetic realization of an earth model built on the geometry of seven interpreted horizons of the
F3 block (Dutch North Sea), with 16 training wells and 8 blind test wells. The true tie of each training well is a
drift b + ∫ exp(g) dτ drawn from a Matérn-3/2 prior fitted to the F3 wells, scaled by a drift factor c (c = 0: no
drift). A method receives what an analyst would have:
- for every well: a 3 × 3 patch of noisy post-stack traces around the well;
- for training wells only: the porosity log and the acoustic impedance log on τ, and unit-boundary anchors
(τ_k exact, t_k = true time + N(0, σ_a²), σ_a = 7 ms);
- the analyst's nominal knowledge (`inputs/analyst.json`): wavelet, warp prior, anchor noise, rock physics.
It must predict the porosity (and optionally its standard deviation) of the centre trace of each test well on
600–1100 ms (126 samples at 4 ms). The test labels are the true porosity on true time, so a perfect tie is not
required to score well, but a wrong tie corrupts the training labels.
## 2. Settings
| family | settings | drift factors c | registered N |
|---|---|---|---|
| nominal (S1) | R10 (SNR 10 dB, all anchors), R0 (0 dB), Rm5 (−5 dB), R0h (0 dB, every second anchor), R10tb (10 dB, top and bottom anchors only) | 0, 0.5, 1, 1.5, 2 | 2, 4, 8, 16 |
| misspecified (S2) | `{R10,Rm5}__{rp_L1, rp_L2}` rock physics (per-unit DT intercept error), `__{wv_L1, wv_L2}` wavelet (mixed/minimum phase), `__wv_Q` (constant Q 80), `__{dr_L1, dr_L2}` drift (hyperparameters ×, step + jitter) | 1 | 4, 16 |
| two-mode (S8) | `{R10,Rm5}__s8d{8,16,32}`: the analyst knows that each tie is one of two warps, t_true or t_true + s·Δ | 1 | 4, 16 |
In S2 the truth is generated with the stated error but `inputs/analyst.json` still describes the nominal model:
methods must not be told about the preset. S2 levels were chosen on the dev split (realizations 902–905). Preset
parameters: `inputs/d2_synth_bench.yaml` (`misspec_presets`). In S8 the task file carries both candidate warps
(`two_mode_t_of_tau_ms`); which one is true is hidden (`truth/…/two_mode_side`).
A task with N training wells uses the first N of the 16 training wells of the file (`train_*[:N]`, and the anchors
with `anchor_well < N`). c = 2 cells are flagged "unstable posterior" in the reference runs and are never primary
evidence.
## 3. Splits
- **test**: realizations 8–15 (5 network seeds 0–4 in the reference runs). Scores on this split are the benchmark
result. Test truth is in the package because the generator is public anyway; do not choose anything (shift,
checkpoint, hyperparameter, training length) from it.
- **dev**: realizations 900–905, same settings. Use them for every design choice. The reference methods chose their
training budgets on dev realizations; the S2 levels were chosen on 902–905.
## 4. Files
```
MANIFEST.json content hashes of every task, truth and input file
README.md this file
inputs/analyst.json units, windows, patch layout, nominal wavelet / rock physics / warp prior / σ_a, metric
inputs/{wavelets.npz, warp_prior_f3.json, horizon_grid.npz, d2_synth_bench.yaml, protocol_bench.yaml}
tasks/index.csv one row per task: split, setting, regime, preset, delta_ms, c, rid, SNR, anchors, paths
tasks/<split>/<setting>/r<rid>_c<c>.npz
truth/<split>/<setting>/r<rid>_c<c>.npz
reference/runs.csv.gz one row per reference run (setting, c, N, rid, seed, method) with every metric
reference/cells.csv, main_table.md cell means and σ_post (copies of benchmark/reference/ in the repository)
```
Task file (`np.load`), times in ms TWT, porosity logs as fractions, labels in porosity units (p.u. = 100 × fraction):
| key | shape | content |
|---|---|---|
| `rid`, `c`, `snr_db`, `anchor_density`, `sigma_a_ms` | scalars | realization, drift factor, regime |
| `t_seis_ms` | (226,) | seismic time axis, 400–1300 ms at 4 ms |
| `t_label_ms` | (126,) | label axis, 600–1100 ms |
| `tau_ms` | (3101,) | log axis τ, 100–1650 ms at 0.5 ms |
| `train_names`, `train_ilxl`, `train_xy` | (16,), (16, 2), (16, 2) | training wells |
| `train_seis` | (16, 9, 226) float32 | 3 × 3 patch: inline offset −1..1 (outer) × crossline −1..1 (inner); centre = index 4 |
| `train_phi_log`, `train_ai_log` | (16, 3101) | porosity (fraction) and AI on τ; `train_ai_log` = AI(`train_phi_log`) with the nominal rock physics |
| `anchor_well`, `anchor_tau_ms`, `anchor_t_ms` | (K,) | anchors of all training wells (well index, τ_k, noisy t_k) |
| `test_names`, `test_ilxl`, `test_xy` | (8,), (8, 2), (8, 2) | test wells, in scoring order |
| `test_seis` | (8, 9, 226) float32 | test patches (same SNR as the training wells) |
| `delta_ms`, `two_mode_t_of_tau_ms` | scalar, (16, 2, 3101) | S8 only: the two candidate warps t(τ) of each training well |
Truth file: `y_test` (8, 126) p.u.; `train_t_of_tau_ms` (16, 3101), `train_b_ms`, `train_g` (true ties, for
diagnostics of a registration step); S8: `two_mode_side`.
## 5. Commands
From the repository root, with the environment of `requirements*.txt` and the inputs listed in `MANIFEST.json`:
```bash
# generate the package (checks the protocol lock, then compares every content hash with benchmark/MANIFEST.json)
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py generate
# or verify a downloaded package
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py check --out /path/to/package
# reference tables from the saved reference runs (needs outputs/p2r and outputs/bench)
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py tables
# score a method
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py score --pred /path/to/predictions --name MyMethod
# end-to-end check of the scorer (copies of saved reference predictions must reproduce the reference rules)
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py selftest
```
All commands take `--out DIR` (default `outputs/bench/package`). `generate` takes `--split test dev`.
### Submission format
```
<pred>/<split>/<setting>/r<rid>_c<c>_n<N>_s<seed>.npz mu (8, 126) p.u., optional sigma (8, 126) > 0
```
`c` as in the task name (`1`, `1.5`, `0.5`), test wells in the order of `test_names`. Submit any subset; a cell
(setting, c, N) counts as complete with 8 realizations × 5 seeds. Without `sigma`, the Gaussian scores (NLL, CRPS,
coverage) are left empty.
### Scores
Per test well (scripts/11 `evaluate`): RMSE and PCC, the **band RMSE** and band PCC after a 4th-order zero-phase
Butterworth high-pass at 6 Hz (primary: the seismic band, where registration error acts), the low-band RMSE, NLL,
CRPS and coverage of the 50/80/90/95% intervals. A run is the mean over the 8 test wells; a cell averages runs over
realization × seed.
On the test split `score` applies the registered rules of protocol_bench (`ml_porosity/benchmark/summary.py`):
- **H2a cell rule** against the best point tie of the cell (lowest mean band RMSE among B3b, B3c, B3c-R):
a method *improves* if its band RMSE ≤ 0.90 × that of the best point tie, or its band PCC ≥ +0.05 higher; the
cell passes if it improves in ≥ 4/5 seeds (seed means over realizations) and in more than half of the
realizations (realization means over seeds).
- **better** against B3d-Sa, M2-Sa and Oracle (PM2, BK2 and Oracle in S8): lower band RMSE in ≥ 4/5 seeds and in
more than half of the realizations, with the ratio of means and a 95% bootstrap CI over realizations.
Reference rows are restricted to the realizations and seeds submitted. Output: `<pred>/score/` (`score.md`,
`rule_point_ties.csv`, `pairs.csv`, `cells.csv`, `runs.csv`, `per_well.csv`).
## 6. Reference methods
All reference methods use the CNN–GRU heteroscedastic network of the repository (d 64, Adam 5e-3, full batch,
64-sample windows, per-well z-score) at budgets chosen on dev; S4 repeats the main cells with a TCN (suffix `-TCN`).
| method | labels |
|---|---|
| Oracle | true tie (ceiling) |
| B3b | marker-calibrated sonic through the anchors |
| B3c | B3b + local NCC shifts against a synthetic |
| B3c-R | B3c with the wavelet at the re-estimated phase |
| B3d | weighted mean warp of an anchor-conditioned bank |
| B3d-Sa | labels at the posterior-mean warp of 1024 SMC particles (registration posterior) |
| M2-Sa | regression with misregistered labels (RML): soft-min loss over a bank of 64 SMC particles |
| B4a–d | anchor-free alignment baselines on B3b labels: hard-min / RML over ±8-sample shifts, soft-DTW, DILATE |
| Ctl-GP | control bank: 64 Gaussian warps with the posterior's mean and covariance |
| PM2, BK2, HM2 | S8: label at the two-mode mean warp; RML over the two-member bank; hard-min over it |
`reference/main_table.md` gives the nominal band RMSE at c = 1. `reference/cells.csv` gives every cell, with
σ_post (the SMC posterior width over the training wells; "wide" at σ_post ≥ 1.5 ms).
Registered results of protocol_bench (11 verdicts, 9 pass): posterior-mean labels (B3d-Sa) beat the best point tie
by ≥ 10% in band RMSE at R10 c = 1.5 (0.853 / 0.796 at N = 4 / 16); the bank gain over B3d-Sa grows with N in
13/13 wide families; under misspecification the gain survives the drift axis (0.862 / 0.798) but not the rock
physics axis (0.940 / 0.934) or the wavelet phase axis (1.023 / 1.042, where the posterior is overconfident); M2-Sa
never hurts (14/14 ≤ 1.02); B4a–d are never the best competitor at c ≤ 1; the TCN backbone keeps the gain; the
two-mode bank beats the two-mode mean at Δ = 16 and 32 ms (BK2/PM2 0.28–0.71). Full statements and both readings of the three verdicts
whose locked extraction differs from the wording: `outputs/bench/summary/verdict_final.md` in the repository.
## 7. What this benchmark is not
- It is synthetic. It says nothing about field skill: on F3 and Volve no method had enough blind-well skill in the
seismic band to test a registration effect.
- It measures registration effects on labels. It makes no calibration claim (in the P2r study every 5-seed
ensemble under-covered).
- One earth-model family (F3 horizon geometry, φ–DT rock physics, a stationary 128 ms wavelet). The S2 settings
probe three axes of misspecification at two levels each (plus one bandwidth setting); they do not cover
misspecification in general.
## 8. Licence and citation
Derived from the F3 Netherlands dataset (dGB Earth Sciences, CC BY-SA 3.0): the horizon grid, the statistical
wavelet and the warp prior are F3 derivatives, so the data package is released under CC BY-SA 3.0 (TODO: verify
the F3 licence wording on the provider's page before deposit). Code: TODO (licence of the repository).
Citation: TODO (paper and Zenodo DOI).
## 9. Deposit (maintainers)
1. `generate` on a clean checkout of the tagged commit; it must report "content hashes equal to
benchmark/MANIFEST.json (1260 files)". The input hashes in `MANIFEST.json` equal the sha256 registered in
`configs/protocol_bench.yaml`.
2. `tables`, then `selftest` (must print `selftest PASS`).
3. `tar -C outputs/bench -cf bench_package_v1.tar package` (about 0.85 GB; the npz files are already compressed),
and record its sha256.
4. Upload with the metadata of `benchmark/zenodo_metadata.json` once the TODO fields (authors, licence check,
related identifiers) are filled; put the DOI in this README and in the paper.

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,19 @@
# Reference band RMSE (p.u.), nominal settings, c = 1
Mean over 8 test realizations × 5 network seeds at the registered budgets (CNN–GRU). σ_post (ms) is the SMC posterior width over the training wells; 'wide' means σ_post ≥ 1.5 ms. Full table: cells.csv.
| method | R10 N=4 | R10 N=16 | R0 N=4 | R0 N=16 | Rm5 N=4 | Rm5 N=16 | R0h N=4 | R0h N=16 | R10tb N=4 | R10tb N=16 |
|---|---|---|---|---|---|---|---|---|---|---|
| Oracle | 0.614 | 0.453 | 0.856 | 0.753 | 1.101 | 1.040 | 0.858 | 0.756 | 0.613 | 0.453 |
| B3b | 0.941 | 0.828 | 1.115 | 1.048 | 1.270 | 1.253 | 1.123 | 1.063 | 1.293 | 1.180 |
| B3c | 0.717 | 0.627 | 1.024 | 0.951 | 1.280 | 1.230 | 1.024 | 0.897 | 0.873 | 0.801 |
| B3c-R | 0.724 | 0.582 | 1.021 | 0.914 | 1.276 | 1.207 | 0.992 | 0.860 | 0.826 | 0.744 |
| B3d | 0.762 | 0.675 | 0.980 | 0.916 | 1.185 | 1.154 | 1.049 | 0.959 | 1.197 | 1.156 |
| B4a | 1.355 | 1.205 | 1.445 | 1.339 | 1.511 | 1.487 | 1.442 | 1.321 | 1.305 | 1.016 |
| B4b | 1.314 | 1.143 | 1.423 | 1.236 | 1.527 | 1.445 | 1.444 | 1.260 | 1.322 | 0.956 |
| B4c | 0.973 | 0.815 | 1.186 | 1.052 | 1.344 | 1.285 | 1.190 | 1.058 | 1.160 | 1.036 |
| B4d | 0.977 | 0.785 | 1.184 | 1.077 | 1.343 | 1.295 | 1.182 | 1.076 | 1.162 | 1.023 |
| B3d-Sa | 0.614 | 0.455 | 0.907 | 0.812 | 1.162 | 1.114 | 0.917 | 0.823 | 0.813 | 0.598 |
| M2-Sa | 0.611 | 0.457 | 0.885 | 0.786 | 1.155 | 1.094 | 0.904 | 0.798 | 0.756 | 0.532 |
| Ctl-GP | 0.610 | 0.458 | 0.895 | 0.802 | 1.162 | 1.096 | 0.913 | 0.799 | 0.775 | 0.541 |
| σ_post | 0.67 | 0.59 | 1.75 | 1.53 | 2.72 | 2.56 | 1.89 | 1.72 | 1.90 | 1.92 |

View File

@@ -0,0 +1,20 @@
{
"_status": "DRAFT, not deposited. Fill the TODO fields, verify the licence, then upload the archive of outputs/bench/package (see benchmark/README.md section 9). Deposit needs the authors' Zenodo account.",
"metadata": {
"upload_type": "dataset",
"title": "A registration-aware synthetic benchmark for sparse-well seismic porosity learning (protocol_bench v1)",
"version": "1.0.0",
"creators": [
{"name": "TODO, Family name, Given names", "affiliation": "TODO", "orcid": "TODO"}
],
"description": "<p>Synthetic seismic-to-porosity tasks in which the time-depth tie of every training well is uncertain and the truth is known. Each task is one realization of an earth model on the geometry of seven interpreted horizons of the F3 block (Dutch North Sea) with 16 training wells (3 x 3 trace patch, porosity and impedance logs on sonic time, noisy unit-boundary anchors) and 8 blind test wells. Settings: five noise and anchor regimes x five drift factors (nominal), seven misspecification presets (rock physics, wavelet, drift), and six two-mode registration settings. Test split: realizations 8-15; dev split: 900-905; 630 tasks. Includes the hidden truth, the analyst's nominal inputs, reference results of 21 method variants (45,200 runs) and content hashes. Generation and scoring code, and the locked protocol, are in the companion repository.</p>",
"access_right": "open",
"license": "cc-by-sa-3.0",
"keywords": ["seismic inversion", "well tie", "porosity", "label noise", "registration uncertainty", "benchmark", "synthetic data", "F3 Netherlands"],
"related_identifiers": [
{"identifier": "TODO repository URL", "relation": "isSupplementTo", "resource_type": "software"},
{"identifier": "TODO paper DOI or preprint", "relation": "isSupplementTo", "resource_type": "publication-article"}
],
"notes": "Derived from the F3 Netherlands dataset (dGB Earth Sciences; CC BY-SA 3.0): horizon grid, statistical wavelet and warp prior. Content hashes: MANIFEST.json (sha256 of array content). Protocol sha256 aa763f0a4f81125ea8441fdfba4361f68246c7a0be1c36d4bf8de2650a91a4c5 (configs/protocol_bench.yaml, locked 2026-10-29 14:39 UTC)."
}
}

File diff suppressed because one or more lines are too long

View File

@@ -59,7 +59,7 @@ Khai báo: Deviation 2 trong `applicability-teapot.md` (băm v2 07:11:29 UTC, tr
## Dùng trong bài (29/10/2026) ## Dùng trong bài (29/10/2026)
- **T3** → bài mục 6.5 (*Detectability of a gain at blind wells*, exploratory), bảng `tab:t3`. Hệ quả 4 (bài mục 4.5: dấu của lợi ích đo được đúng với dấu thật chỉ khi σ_r < σ/√2) dự báo điểm cắt σ/√2 = 3,0/4,1/5,1 ms; tỉ số band RMSE trung vị cắt 1 ở 3,6–4,3 ms (ba ô N = 16). Bài ghi rõ phép phân tích được khai báo trước khi chạy nhưng sau khi cả hai field gate trượt, và nêu Deviation 1. - **T3** → bài mục 6.6 (từ 02/11/2026; trước đó 6.5) (*Detectability of a gain at blind wells*, exploratory), bảng `tab:t3`. Hệ quả 4 (bài mục 4.5: dấu của lợi ích đo được có thể đúng với dấu thật chỉ khi σ_r < σ/√2; từ 02/11/2026 bài ghi đây là điều kiện cần ở mọi tần số nhưng không đủ, `docs/plan.md` §12 ý 32) đặt điểm cắt dưới σ/√2 = 3,0/4,1/5,1 ms khi không có shrinkage, và bằng σ/√2 ở bậc đầu; tỉ số band RMSE trung vị cắt 1 ở 3,6/3,8/4,3 ms (ba ô N = 16, nội suy tuyến tính), thấp hơn σ/√2 ở R0 và Rm5, cao hơn 0,6 ms ở R10, điều shrinkage cho phép. Bài ghi rõ phép phân tích được khai báo trước khi chạy nhưng sau khi cả hai field gate trượt, và nêu Deviation 1.
- **C1–C4 và phép kiểm hồi cứu F3, Volve** → bài mục 6.6, đoạn *Neither test could have detected the effect*: ghi là post hoc, với ngưỡng C1, C2 lấy cơ học từ Thí nghiệm 2 (P2r). - **C1–C4 và phép kiểm hồi cứu F3, Volve** → bài mục 6.7 (trước 02/11/2026 là 6.6), đoạn *Neither test could have detected the effect*: ghi là post hoc, với ngưỡng C1, C2 lấy cơ học từ Thí nghiệm 2 (P2r).
- **Teapot T0 và pilot P-a** → bài mục 6.6, đoạn *Limits of field validation*: ghi là post hoc, exploratory; dùng 152 giếng, 4 bảng TD, tối đa 2 giếng có reference độc lập, σ̂_knot 6,75 ms (CI 90% 4,1–9,4) so với 1,5 ms. - **Teapot T0 và pilot P-a** → bài mục 6.7, đoạn *Limits of field validation*: ghi là post hoc, exploratory; dùng 152 giếng, 4 bảng TD, tối đa 2 giếng có reference độc lập, σ̂_knot 6,75 ms (CI 90% 4,1–9,4) so với 1,5 ms.
- Nguồn số liệu từng câu: `paper/README.md`. Quyết định dừng Teapot: `docs/plan.md` §12 ý 23; `report.html` D-11. - Nguồn số liệu từng câu: `paper/README.md`. Quyết định dừng Teapot: `docs/plan.md` §12 ý 23; `report.html` D-11.

View File

@@ -1,6 +1,6 @@
# protocol_bench: runner, hiệu chuẩn mức sai mô hình, tái lập P2r và bản nháp giao thức # protocol_bench: runner, hiệu chuẩn mức sai mô hình, tái lập P2r và bản nháp giao thức
Ngày viết: **29/10/2026** (phase P6, mức B; plan §12 ý 22 và 26; lịch §6.1 dự kiến 2–3/11, làm sớm). Trạng thái: **ĐÃ KHOÁ 14:39:20 UTC 29/10/2026** sau khi điều phối duyệt bản nháp và yêu cầu 7 sửa đổi (mục 1.4); `configs/protocol_bench.sha256` = `aa763f0a4f81125ea8441fdfba4361f68246c7a0be1c36d4bf8de2650a91a4c5`, `configs/protocol_bench.lock.json` (code `5ea2eb17…`, torch 2.14.0+cu130, 8 input, 102 artifact P2r, fingerprint rid 8/902 khớp). Chạy chính 29/10 14:43 → 30/10 02:16 UTC, đã xong toàn bộ (S1 560 ô train, S2 224 posterior + 224 train, S3+S4+S8 384 train; chi tiết `docs/plan.md` §12 ý 26); chưa summarize. Code commit 381b5ff. Tài liệu này ghi (1) thiết kế runner `ml_porosity/benchmark/` và CLI, (2) kết quả kiểm tra tái lập P2r qua runner mới, (3) hiệu chuẩn mức L1/L2 của ba trục sai mô hình trên realization dev, (4) tóm tắt giao thức `configs/protocol_bench.yaml` (ô, giả thuyết, luật), (5) ước tính chi phí và phân bổ GPU, (6) tác dụng phụ lên hash code của lock F3/Volve, (7) rủi ro còn mở. Mục 2 và 3 được điền khi có số; mọi số dev đều ghi rõ rid, N, regime. Ngày viết: **29/10/2026** (phase P6, mức B; plan §12 ý 22 và 26; lịch §6.1 dự kiến 2–3/11, làm sớm). Trạng thái: **ĐÃ KHOÁ 14:39:20 UTC 29/10/2026** sau khi điều phối duyệt bản nháp và yêu cầu 7 sửa đổi (mục 1.4); `configs/protocol_bench.sha256` = `aa763f0a4f81125ea8441fdfba4361f68246c7a0be1c36d4bf8de2650a91a4c5`, `configs/protocol_bench.lock.json` (code `5ea2eb17…`, torch 2.14.0+cu130, 8 input, 102 artifact P2r, fingerprint rid 8/902 khớp). Chạy chính 29/10 14:43 → 30/10 02:16 UTC, đã xong toàn bộ (S1 560 ô train, S2 224 posterior + 224 train, S3+S4+S8 384 train; chi tiết `docs/plan.md` §12 ý 26). Summarize xong 02/11/2026 02:02 UTC; verdict cuối theo đúng lời phát biểu do `scripts/36_bench_verdicts.py` ghi (9/11 đạt; mục 8, `docs/plan.md` §12 ý 28). S7 đóng gói xong cùng ngày (`scripts/37_bench_package.py`, `benchmark/`; mục 9, §12 ý 29). Code commit 381b5ff. Tài liệu này ghi (1) thiết kế runner `ml_porosity/benchmark/` và CLI, (2) kết quả kiểm tra tái lập P2r qua runner mới, (3) hiệu chuẩn mức L1/L2 của ba trục sai mô hình trên realization dev, (4) tóm tắt giao thức `configs/protocol_bench.yaml` (ô, giả thuyết, luật), (5) ước tính chi phí và phân bổ GPU, (6) tác dụng phụ lên hash code của lock F3/Volve, (7) rủi ro còn mở, (8) kết quả và verdict, (9) gói benchmark S7. Mục 2 và 3 được điền khi có số; mọi số dev đều ghi rõ rid, N, regime.
Liên quan: `docs/research/pivot-theory-benchmark.md` §2.2 (S1–S8) và §6; `docs/research/bench-generator.md` (bộ sinh misspec, QC rid 902); `configs/protocol_p2r.yaml` (khoá; nguồn của regime, phương pháp, ngân sách, luật); `configs/protocol_p2.yaml` (khoá; registration, training, metric); bản đồ code của phase 1 (scratchpad `bench-code-map.md`, không theo dõi trong git). Liên quan: `docs/research/pivot-theory-benchmark.md` §2.2 (S1–S8) và §6; `docs/research/bench-generator.md` (bộ sinh misspec, QC rid 902); `configs/protocol_p2r.yaml` (khoá; nguồn của regime, phương pháp, ngân sách, luật); `configs/protocol_p2.yaml` (khoá; registration, training, metric); bản đồ code của phase 1 (scratchpad `bench-code-map.md`, không theo dõi trong git).
@@ -245,3 +245,42 @@ Kiểm tra phụ (dev rid 902, R10, c = 1, N = 4): runner và `scripts/33 --smc`
5. **Ô P2r-grid trong S1 không chạy lại** (đọc từ `outputs/p2r`): hợp lệ vì tái lập từng bit (mục 2), nhưng nếu môi trường đổi (torch/cuDNN) trước 4/11 thì S1 trộn hai môi trường; khi đó chạy lại ô repro để kiểm. 5. **Ô P2r-grid trong S1 không chạy lại** (đọc từ `outputs/p2r`): hợp lệ vì tái lập từng bit (mục 2), nhưng nếu môi trường đổi (torch/cuDNN) trước 4/11 thì S1 trộn hai môi trường; khi đó chạy lại ô repro để kiểm.
6. **Dev-budgets TCN**: đã xong trước khi khoá; mọi phương pháp TCN chọn 125 vòng lặp (biên dưới của danh sách ứng viên) — S4 so sánh TCN ở 125 với CNN-GRU ở ngân sách P2r (125–500); nhánh 500 cho cả hai cho phép so sánh cùng ngân sách (disclosed). 6. **Dev-budgets TCN**: đã xong trước khi khoá; mọi phương pháp TCN chọn 125 vòng lặp (biên dưới của danh sách ứng viên) — S4 so sánh TCN ở 125 với CNN-GRU ở ngân sách P2r (125–500); nhánh 500 cho cả hai cho phép so sánh cùng ngân sách (disclosed).
7. **Số dev 904/905**: chạy xác nhận mức đã chọn; nếu trái ngược rõ (ví dụ wv_L1 không còn thắng point tie ở R10 trên 3/4 rid), mức được cân nhắc lại trước khi khoá và ghi ở mục 3. 7. **Số dev 904/905**: chạy xác nhận mức đã chọn; nếu trái ngược rõ (ví dụ wv_L1 không còn thắng point tie ở R10 trên 3/4 rid), mức được cân nhắc lại trước khi khoá và ghi ở mục 3.
---
## 8. Kết quả và verdict (02/11/2026)
Nguồn: `outputs/bench/summary/verdict_final.json` và `verdict_final.md` (do `scripts/36_bench_verdicts.py` ghi), `verdict.json` và `summary.md` (code đã khoá, `scripts/34_run_bench.py summarize`). Chi tiết đầy đủ và hệ quả cho bài: `docs/plan.md` §12 ý 28.
- **Kiểm trước:** lock khớp ở mọi khoá; 8.799 file `outputs/bench/` khớp `docs/research/unpushed_outputs.sha256`; đủ số ô ở mọi study.
- **Deviation thực thi (D-13):** code tổng hợp đã khoá khác lời phát biểu ở ba chỗ: S1-H1 trả null vì cần đúng 2 dòng, mà S1 có 4 giá trị N; S2-H1 không có khoá `pass` mức trên; S3-H1 đưa Ctl-GP vào tập đối thủ. Không sửa code đã khoá. Script 36 (ngoài tập hash, gọi `freeze(check=True)` trước) đọc lại đúng phát biểu. Hai cách đọc đều được báo cáo; chỉ S3-H1 đổi kết luận.
- **Verdict theo phát biểu, 9/11 đạt.** Tỉ số là band RMSE của B3d-Sa chia cho tie điểm tốt nhất, ở N = 4 / 16:
| Verdict | Kết luận | Số liệu |
|---|---|---|
| S1-H1 | đạt (code: null) | R10, c = 1,5: 0,853 / 0,796 (B3c-R) |
| S1-H2 | đạt | 13/13 họ rộng; ρ = −0,47, p < 10⁻⁴ |
| S2-H1 rock physics | **không đạt** (dự đoán đạt) | rp_L1 0,940 / 0,934 |
| S2-H1 wavelet | **không đạt** (dự đoán đạt) | wv_L1 1,023 / 1,042; posterior quá tự tin (cov90 0,17 / 0,10) |
| S2-H1 drift | đạt (dự đoán không chắc) | dr_L1 0,862 / 0,798 |
| S2-H2 | đạt | 14/14 cặp ≤ 1,02 |
| S3-H1 | đạt ở R10, R0, Rm5 (code: không đạt) | R10 0,857 / 0,782; R0 0,888 / 0,888; Rm5 0,915 / 0,923 |
| S4-H1 | đạt | TCN 0,840 / 0,823 |
| S4-H2 | đạt | M2-Sa/B3d-Sa: R0h 0,977, Rm5 0,983 |
| S8-H1 | đạt | Ĥ trong băng đảo dấu −0,70 / −0,49 |
| S8-H2 | đạt | BK2/PM2: R10 0,34 / 0,28; Rm5 0,71 / 0,64 |
- **Đối chiếu với rủi ro mục 7:** S1-H2 (dự đoán mới) đạt. Trục drift của S2-H1 đạt. Hai trục được dự đoán đạt lại trượt. Trên dev (mục 3.1), wv_L1 đã quá tự tin (cov90 0,11) nhưng warp SMC vẫn tốt hơn B3c ở 4/4 rid. Trên realization 8–15, sự quá tự tin đó đủ xoá lợi ích H2a về porosity. Với rp_L1, warp gần danh nghĩa (mục 3.4 ý 1), nhưng lợi ích porosity vẫn co lại dưới ngưỡng 0,90.
- **Ghi chú về chữ "calibrated" của S8 (02/11/2026, khi viết bài).** Lời phát biểu S8-H2 trong protocol đã khoá gọi BK2 là "a calibrated bank: the truth is a member". Đây chỉ là nghĩa yếu: warp thật là một thành viên của bank. BK2 không phải bank hiệu chỉnh theo Mệnh đề 4 của bài (bank là mẫu đúng của posterior). Theo Hệ quả 3, cấu trúc (a), khi λ → 0 transfer của BK2 là cos²(πfΔ), không phải 1. Đo được ở N = 16, trong băng đảo dấu 1/(2Δ) < f < 3/(2Δ), BK2 có transfer 0,92–1,00, trong khi trung bình cos² chỉ là 0,05–0,59 (`scripts/38_bench_figures.py --flipband`; post hoc, không phải verdict). Kết quả này khớp với việc responsibility tái đăng ký nhãn (Remark 1 của bài). Verdict S8-H2 không đổi. Bài (Sec. 6.5) ghi rõ nghĩa yếu này và không gọi BK2 là bank hiệu chỉnh.
## 9. Gói benchmark S7 (02/11/2026)
`scripts/37_bench_package.py` nằm ngoài tập hash của lock và chỉ đọc output đã khoá. `generate` và `tables` chạy `freeze(check=True)` trước. Hướng dẫn cho người dùng benchmark (tiếng Anh): `benchmark/README.md`. Chi tiết số: `docs/plan.md` §12 ý 29.
- **Task.** Mỗi file `tasks/<split>/<setting>/r<rid>_c<c>.npz` chứa đúng quan sát của runner (`Inputs.observe`): 16 giếng pool gồm patch 3 × 3, φ và AI trên τ, anchor; 8 giếng test chỉ có patch. Task dùng N giếng thì lấy N giếng đầu. Setting: 5 regime danh nghĩa × c ∈ {0; 0,5; 1; 1,5; 2}; 14 setting S2 (`R10__rp_L1`, …) và 6 setting S8 (`R10__s8d16`, …) ở c = 1. Split test là rid 8–15, dev là 900–905; tổng 630 task.
- **Truth ẩn** nằm trong `truth/`: `y_test` (p.u.), warp thật của giếng train, và dấu s của S8. Truth test được công bố vì bộ sinh vốn công khai; README yêu cầu mọi lựa chọn thiết kế chỉ dựa trên dev.
- **Hash.** `benchmark/MANIFEST.json` ghi sha256 nội dung mảng của 1.260 file và sha256 của 5 input; sha256 input khớp sha256 đăng ký trong protocol. Lần `generate` thứ hai tái lập đủ 1.260 hash.
- **Chấm điểm.** `score` dùng metric của scripts/11 và luật ô H2a cùng luật `better` của `summary.py`, chỉ so với các realization và seed đã nộp. `selftest` chép dự đoán đã lưu của phương pháp tham chiếu thành một bài nộp và đạt: metric, truth và luật đều khớp. Ví dụ S1-H1 cho 0,8529 / 0,7964, khớp mục 8.
- **Bảng tham chiếu.** `benchmark/reference/cells.csv` (1.130 dòng ô, kèm σ_post) và `main_table.md`, tính từ 45.200 run.
- **Chưa làm:** deposit Zenodo. Cần tài khoản và danh sách tác giả của người dùng, và cần kiểm giấy phép trước. Metadata nháp nằm ở `benchmark/zenodo_metadata.json`.

View File

@@ -1,6 +1,6 @@
# Phân tích hiện trạng và hướng chuyển sang bài lý thuyết + synthetic benchmark # Phân tích hiện trạng và hướng chuyển sang bài lý thuyết + synthetic benchmark
Ngày viết: **29/10/2026**. Trạng thái: **đã chốt** ở mục 6 (29/10/2026); mức A viết xong sớm ngày 29/10 (`docs/plan.md` §12 ý 24). Mục 0–5 giữ nguyên phân tích lúc viết; chỗ nào đã đổi có ghi chú *Cập nhật* hoặc *Sửa* kèm ngày. Mọi số liệu dưới đây lấy từ `docs/plan.md` §12, `docs/theory.md`, `outputs/p2r/summary/`, `outputs/p3/summary/`, `outputs/p4/summary/`, `outputs/p4x/summary/` và bản nháp `paper/sections/`. Không có kết quả mới nào được tính trong tài liệu này. Ngày viết: **29/10/2026**. Trạng thái: **đã chốt** ở mục 6 (29/10/2026); mức A viết xong sớm ngày 29/10 (`docs/plan.md` §12 ý 24). Benchmark S1–S8 (P6) đã chạy (29–30/10) và tổng hợp ngày 02/11/2026: 9/11 verdict đạt, S2-H1 trượt ở trục rock physics và wavelet (`docs/plan.md` §12 ý 28). S7 đóng gói xong cùng ngày, trừ deposit Zenodo (§12 ý 29). Các mục 1–2 dưới đây là phân tích khoảng trống tại 29/10, giữ nguyên làm lịch sử. Mục 0–5 giữ nguyên phân tích lúc viết; chỗ nào đã đổi có ghi chú *Cập nhật* hoặc *Sửa* kèm ngày. Mọi số liệu dưới đây lấy từ `docs/plan.md` §12, `docs/theory.md`, `outputs/p2r/summary/`, `outputs/p3/summary/`, `outputs/p4/summary/`, `outputs/p4x/summary/` và bản nháp `paper/sections/`. Không có kết quả mới nào được tính trong tài liệu này.
Bối cảnh: cả hai field test đều âm (G-C trên F3, G-D trên Volve). Plan §9 đã liệt kê sẵn **Pivot 1** ("chuyển thành bài phân tích: lý thuyết, benchmark và đánh giá có xét registration; phương pháp chỉ là phần phụ"). Tài liệu này rà lại toàn bộ đề tài để tìm các vấn đề tồn đọng, rồi đề xuất cách triển khai Pivot 1 thành một bài **lý thuyết + benchmark**. Bối cảnh: cả hai field test đều âm (G-C trên F3, G-D trên Volve). Plan §9 đã liệt kê sẵn **Pivot 1** ("chuyển thành bài phân tích: lý thuyết, benchmark và đánh giá có xét registration; phương pháp chỉ là phần phụ"). Tài liệu này rà lại toàn bộ đề tài để tìm các vấn đề tồn đọng, rồi đề xuất cách triển khai Pivot 1 thành một bài **lý thuyết + benchmark**.
@@ -167,7 +167,7 @@ Không "first"; không gọi synthetic là generalization ra field; không claim
- A1: abstract (292 từ sau lượt tự sửa A6), intro, đóng góp C1–C4, discussion, conclusion, tiêu đề, keywords, `paper/highlights.txt` viết lại theo khung Pivot 1. F3 và Volve thành mục "scope" (bài mục 6.6); chi tiết sang Phụ lục B. - A1: abstract (292 từ sau lượt tự sửa A6), intro, đóng góp C1–C4, discussion, conclusion, tiêu đề, keywords, `paper/highlights.txt` viết lại theo khung Pivot 1. F3 và Volve thành mục "scope" (bài mục 6.6); chi tiết sang Phụ lục B.
- A2: T1 thành Mệnh đề 3–4 (kèm sửa cách đọc cận, xem hàng T1 ở mục 2.1), T4 thành Mệnh đề 5, T8 thành Hệ quả 3; thêm Nhận xét 1 (λ > 0), Mệnh đề 6 và Hệ quả 4 (reference lệch, dung sai σ_r < σ/√2). - A2: T1 thành Mệnh đề 3–4 (kèm sửa cách đọc cận, xem hàng T1 ở mục 2.1), T4 thành Mệnh đề 5, T8 thành Hệ quả 3; thêm Nhận xét 1 (λ > 0), Mệnh đề 6 và Hệ quả 4 (reference lệch, dung sai σ_r < σ/√2).
- A3: `scripts/30_t4_coverage.py` → `outputs/t4/` (bài mục 6.3, Bảng `tab:t4`). - A3: `scripts/30_t4_coverage.py` → `outputs/t4/` (bài mục 6.3, Bảng `tab:t4`).
- A4: `scripts/27_t3_power.py` → `outputs/t3/` (bài mục 6.5). Khác với phác thảo ở bảng trên: reference là nhãn thật đọc tại một warp nhiễu loạn có độ lớn σ_ref (không phải nhãn point tie), và luật được đánh giá là sign test một phía; luật k-of-n chỉ dùng để chỉ ra nó không phải phép kiểm. Khai báo trước ở `docs/research/applicability-teapot.md` (Deviation 1: mở rộng lưới σ_ref). - A4: `scripts/27_t3_power.py` → `outputs/t3/` (bài mục 6.5; từ 02/11/2026 là 6.6, sau khi Thí nghiệm 3 thành mục 6.5). Khác với phác thảo ở bảng trên: reference là nhãn thật đọc tại một warp nhiễu loạn có độ lớn σ_ref (không phải nhãn point tie), và luật được đánh giá là sign test một phía; luật k-of-n chỉ dùng để chỉ ra nó không phải phép kiểm. Khai báo trước ở `docs/research/applicability-teapot.md` (Deviation 1: mở rộng lưới σ_ref).
- A5: đoạn "Label noise and errors in variables" ở bài mục 2 (Mnih & Hinton 2012 đọc toàn văn; Balakrishnan 1962 chỉ có metadata). - A5: đoạn "Label noise and errors in variables" ở bài mục 2 (Mnih & Hinton 2012 đọc toàn văn; Balakrishnan 1962 chỉ có metadata).
- A6: `docs/plan.md` §12 ý 22–24, `AGENTS.md`, `report.html`, `docs/theory.md` mục 6. Trong A6, agent phát hiện và sửa hai nhận định sai của chính mình về cận ρ*: hệ số giữa hai cấu trúc, và câu "lợi ích vượt cận" (`docs/plan.md` §12 ý 24). - A6: `docs/plan.md` §12 ý 22–24, `AGENTS.md`, `report.html`, `docs/theory.md` mục 6. Trong A6, agent phát hiện và sửa hai nhận định sai của chính mình về cận ρ*: hệ số giữa hai cấu trúc, và câu "lợi ích vượt cận" (`docs/plan.md` §12 ý 24).

View File

@@ -33,4 +33,5 @@ Danh sách từng file của `outputs/`, kèm sha256 (21.987 file, tạo 30/10 k
- Kiểm tra dữ liệu: `python scripts/00_data_manifest.py --check` và lệnh `sha256sum -c` ở trên. - Kiểm tra dữ liệu: `python scripts/00_data_manifest.py --check` và lệnh `sha256sum -c` ở trên.
- Lock ghi torch 2.14.0+cu130. Nếu môi trường mới khác, `freeze(check=True)` báo lệch ở khoá `environment`. Khi đó **không** sửa lock: mọi lần chạy thêm phải là một phiên bản protocol mới, có ghi deviation. `summarize` không gọi `freeze(check=True)`. - Lock ghi torch 2.14.0+cu130. Nếu môi trường mới khác, `freeze(check=True)` báo lệch ở khoá `environment`. Khi đó **không** sửa lock: mọi lần chạy thêm phải là một phiên bản protocol mới, có ghi deviation. `summarize` không gọi `freeze(check=True)`.
- Các session tmux (`p6_*`) không đi theo bản sync. Mọi driver P6 đã xong lúc 02:16 UTC 30/10 và supervisor đã dừng (xem `docs/plan.md` §12 ý 26); không có gì cần resume. Bước tiếp theo là `python scripts/34_run_bench.py summarize`. - Các session tmux (`p6_*`) không đi theo bản sync. Mọi driver P6 đã xong lúc 02:16 UTC 30/10 và supervisor đã dừng (xem `docs/plan.md` §12 ý 26); không có gì cần resume. Summarize đã chạy trên server mới ngày 02/11/2026 (lock và sha256 của `outputs/bench/` khớp trước khi chạy; `docs/plan.md` §12 ý 28).
- `outputs/bench/package/` (S7, 02/11/2026, khoảng 845 MB) sinh sau bản sync nên không có trong `unpushed_outputs.sha256`. Không cần chép sang máy khác: chạy `scripts/37_bench_package.py generate` để sinh lại; lệnh này so sha256 nội dung với `benchmark/MANIFEST.json` (trong git). Sau đó chạy `tables` (cần `outputs/p2r` và `outputs/bench`).

View File

@@ -1,6 +1,6 @@
# Bài giảng: học porosity từ seismic khi không chắc nhãn nằm ở đâu # Bài giảng: học porosity từ seismic khi không chắc nhãn nằm ở đâu
Cập nhật 29/10/2026. Phản ánh trạng thái dự án: P0–P4 đã xong (G-C và G-D đều không đạt tiêu chí claim), đang viết bài (P5). Từ 29/10 bài theo Pivot 1: lý thuyết + benchmark synthetic, hạn thứ 7, 14/11/2026; phần viết mức A đã xong sớm (mục 11.7). Cập nhật 02/11/2026. Phản ánh trạng thái dự án: P0–P4 đã xong (G-C và G-D đều không đạt tiêu chí claim), đang viết bài (P5). Từ 29/10 bài theo Pivot 1: lý thuyết + benchmark synthetic, hạn thứ 7, 14/11/2026; phần viết mức A đã xong sớm; benchmark P6 đã chạy và tổng hợp ngày 02/11 (9/11 verdict đạt; mục 11.7); các mục kết quả đã viết vào bài cùng ngày.
**Bài giảng này dành cho ai.** Người chưa biết gì về địa vật lý, học máy hay thống kê Bayes. Chỉ cần toán phổ thông: hàm số, trung bình, phương sai, hàm mũ. Mỗi khái niệm được giải thích bằng ví dụ đời thường trước, rồi mới đến công thức. Công thức nào khó thì có câu "đọc bằng lời" ngay bên dưới. **Bài giảng này dành cho ai.** Người chưa biết gì về địa vật lý, học máy hay thống kê Bayes. Chỉ cần toán phổ thông: hàm số, trung bình, phương sai, hàm mũ. Mỗi khái niệm được giải thích bằng ví dụ đời thường trước, rồi mới đến công thức. Công thức nào khó thì có câu "đọc bằng lời" ngay bên dưới.
@@ -579,13 +579,15 @@ Một điểm đáng chú ý: registration trên Volve "khỏe" hơn F3. Pha wav
**Lý thuyết mở rộng** (bài mục 4.3–4.5, chứng minh ở Phụ lục A; bản tiếng Việt ở [theory.md](theory.md) mục 6): **Lý thuyết mở rộng** (bài mục 4.3–4.5, chứng minh ở Phụ lục A; bản tiếng Việt ở [theory.md](theory.md) mục 6):
- *Hai kiểu sai số của tie (Mệnh đề 3).* Nếu sai số tie độc lập với nhãn thật (kiểu *classical*), mạng học ra ảnh mờ như Mệnh đề 1. Nếu sai số độc lập với những gì ta đã biết (kiểu *Berkson*), như khi lấy tie là trung bình posterior, thì ngược lại: mạng học ra ảnh *sắc hơn* thật. Cận 1/B(σ_post) dùng cho H2b là cận của kiểu classical. Kiểu Berkson cho cận thấp hơn. Hệ số giữa hai tích phân, e^{4π²σ²f²}, nhỏ ở tần số thấp, nhưng phần méo (trọng số f⁴) nằm quanh 70 Hz, nơi hệ số lớn: ở σ = 2 ms, tích phân Berkson gấp 2,1–2,6 lần. Bản trước ghi "hệ số dưới 1,17". Con số đó sai vì chỉ xét tới 25 Hz (sửa 29/10). - *Hai kiểu sai số của tie (Mệnh đề 3).* Nếu sai số tie độc lập với nhãn thật (kiểu *classical*), mạng học ra ảnh mờ như Mệnh đề 1. Nếu sai số độc lập với những gì ta đã biết (kiểu *Berkson*), như khi lấy tie là trung bình posterior, thì ngược lại: mạng học ra ảnh *sắc hơn* thật. Cận 1/B(σ_post) dùng cho H2b là cận của kiểu classical. Kiểu Berkson cho cận thấp hơn. Hệ số giữa hai tích phân, e^{4π²σ²f²}, nhỏ ở tần số thấp, nhưng phần méo (trọng số f⁴) nằm quanh 70 Hz, nơi hệ số lớn: ở σ = 2 ms, tích phân Berkson gấp 2,1–2,6 lần. Bản trước ghi "hệ số dưới 1,17". Con số đó sai vì chỉ xét tới 25 Hz (sửa 29/10).
- *Bank hiệu chỉnh (Mệnh đề 4).* Nếu bank là mẫu đúng của posterior, học trên cả bank cho cùng nghiệm quần thể với học trên nhãn thật. Nhưng lợi ích quần thể so với nhãn điểm chỉ ở *bậc bốn* theo σ, nên rất nhỏ khi posterior hẹp. - *Bank hiệu chỉnh (Mệnh đề 4).* Nếu bank là mẫu đúng của posterior, học trên cả bank cho cùng nghiệm quần thể với học trên nhãn thật. Nhưng lợi ích quần thể so với nhãn điểm chỉ ở *bậc bốn* theo σ, nên rất nhỏ khi posterior hẹp.
- *Coverage (Mệnh đề 5)* và *reference lệch (Mệnh đề 6, Hệ quả 4).* Nếu reference dùng để chấm cũng lệch, phép so sánh hai phương pháp chỉ cho đúng chiều khi sai số của reference nhỏ hơn σ/√2. - *Coverage (Mệnh đề 5)* và *reference lệch (Mệnh đề 6, Hệ quả 4).* Nếu reference dùng để chấm cũng lệch, phép so sánh hai phương pháp chỉ có thể cho đúng chiều khi sai số của reference nhỏ hơn σ/√2 (điều kiện cần ở mọi tần số, không đủ; sửa 02/11/2026).
**Kiểm tra post hoc trên P2r** ([31_p2r_posthoc.py](../scripts/31_p2r_posthoc.py), [30_t4_coverage.py](../scripts/30_t4_coverage.py); bài mục 6.3). Theo cận classical đã đăng ký, lợi ích của bank vượt cận quần thể ở 7/8 ô rộng khi tính tại σ_post và 6/8 ô khi tính tại sai số warp. Cận Berkson, tính post hoc, là cấu trúc tự nhiên cho nhãn tại warp trung bình. Theo cận này chỉ 3/8 ô vượt tại σ_post, cả ba ở c = 1 và hai ô sát cận. Tại sai số warp thì nhiều nhất 1/8 ô vượt. Vì vậy không nói được rằng lợi ích "vượt cận". Cũng chưa kiểm sai số thật có kiểu Berkson hay không. M2-Sa vẫn kém Oracle ở mọi ô rộng (4–63%). Nguồn lợi ích còn mở (T2, sẽ khai báo trước rồi mới chạy). Mọi ensemble quá hẹp, và độ dài huấn luyện lẫn với nguồn nhãn nên chưa tách được nguyên nhân. **Kiểm tra post hoc trên P2r** ([31_p2r_posthoc.py](../scripts/31_p2r_posthoc.py), [30_t4_coverage.py](../scripts/30_t4_coverage.py); bài mục 6.3). Theo cận classical đã đăng ký, lợi ích của bank vượt cận quần thể ở 7/8 ô rộng khi tính tại σ_post và 6/8 ô khi tính tại sai số warp. Cận Berkson, tính post hoc, là cấu trúc tự nhiên cho nhãn tại warp trung bình. Theo cận này chỉ 3/8 ô vượt tại σ_post, cả ba ở c = 1 và hai ô sát cận. Tại sai số warp thì nhiều nhất 1/8 ô vượt. Vì vậy không nói được rằng lợi ích "vượt cận". M2-Sa vẫn kém Oracle ở mọi ô rộng (4–63%). T2 (exploratory, khai báo trước; [t2-results.md](research/t2-results.md)) cho thấy sai số nhãn của B3d-Sa đúng là kiểu Berkson ở c = 1, nên cận Berkson là cận áp dụng và lợi ích H2b không vượt hiệu chỉnh quần thể. Một bank nhiễu GP cùng trung bình và hiệp phương sai posterior lấy được phần lớn lợi ích ở c = 1 (tăng cường nhãn). Tái đăng ký ngầm có thật (8/8 ô rộng). Không có bằng chứng cho cơ chế đa mode. Khoảng một phần ba khoảng cách giữa nhãn trung bình posterior và Oracle là do độ dài huấn luyện. Mọi ensemble quá hẹp, và độ dài huấn luyện lẫn với nguồn nhãn nên chưa tách được nguyên nhân.
**Một field test cần gì** (T3, [27_t3_power.py](../scripts/27_t3_power.py); bài mục 6.5). Lấy dự đoán đã lưu của P2r rồi chấm lại bằng một reference cố ý lệch σ_ref. Với reference chính xác, sign test cần 5–18 giếng blind để đạt lực 0,8 ở phần lớn các ô; với σ_ref từ 3 ms trở lên thì 40 giếng cũng không đủ. Luật "≥ k/n giếng cải thiện" của G-C, G-D thực ra không phải phép kiểm: nó đạt ngẫu nhiên với xác suất 0,31 khi có 4 giếng và 0,11 khi có 6 giếng. **Một field test cần gì** (T3, [27_t3_power.py](../scripts/27_t3_power.py); bài mục 6.6). Lấy dự đoán đã lưu của P2r rồi chấm lại bằng một reference cố ý lệch σ_ref. Với reference chính xác, sign test cần 5–18 giếng blind để đạt lực 0,8 ở phần lớn các ô; với σ_ref từ 3 ms trở lên thì 40 giếng cũng không đủ. Luật "≥ k/n giếng cải thiện" của G-C, G-D thực ra không phải phép kiểm: nó đạt ngẫu nhiên với xác suất 0,31 khi có 4 giếng và 0,11 khi có 6 giếng.
**Điều kiện áp dụng và Teapot Dome** (exploratory; [applicability-teapot.md](research/applicability-teapot.md), [applicability-results.md](research/applicability-results.md); bài mục 6.6). Bốn điều kiện để một field test có ý nghĩa với kết quả synthetic: mạng có kỹ năng ở giếng blind trong băng seismic (C1), posterior tie đủ rộng (C2, chỉ cho so sánh với nhãn trung bình posterior), σ_a xác định được bằng dữ liệu thời gian–độ sâu độc lập ở ít nhất 3 giếng ngoài tập test (C3), và đủ giếng cho phép kiểm có lực (C4). F3 và Volve trượt C1, đạt C2 ([26_applicability.py](../scripts/26_applicability.py)). Thử Teapot Dome: chỉ tối đa 2 giếng có bảng thời gian–độ sâu độc lập (T0 trượt), và pilot dùng cặp horizon–top làm reference thay thế cho sai số 6,75 ms so với dung sai 1,5 ms (P-a trượt) ([28_teapot_inventory.py](../scripts/28_teapot_inventory.py), [29_teapot_pilot.py](../scripts/29_teapot_pilot.py)). Teapot dừng; bài không có field test mới. **Điều kiện áp dụng và Teapot Dome** (exploratory; [applicability-teapot.md](research/applicability-teapot.md), [applicability-results.md](research/applicability-results.md); bài mục 6.7). Bốn điều kiện để một field test có ý nghĩa với kết quả synthetic: mạng có kỹ năng ở giếng blind trong băng seismic (C1), posterior tie đủ rộng (C2, chỉ cho so sánh với nhãn trung bình posterior), σ_a xác định được bằng dữ liệu thời gian–độ sâu độc lập ở ít nhất 3 giếng ngoài tập test (C3), và đủ giếng cho phép kiểm có lực (C4). F3 và Volve trượt C1, đạt C2 ([26_applicability.py](../scripts/26_applicability.py)). Thử Teapot Dome: chỉ tối đa 2 giếng có bảng thời gian–độ sâu độc lập (T0 trượt), và pilot dùng cặp horizon–top làm reference thay thế cho sai số 6,75 ms so với dung sai 1,5 ms (P-a trượt) ([28_teapot_inventory.py](../scripts/28_teapot_inventory.py), [29_teapot_pilot.py](../scripts/29_teapot_pilot.py)). Teapot dừng; bài không có field test mới.
**Benchmark P6** (`configs/protocol_bench.yaml`, khoá 29/10; chạy 29/10 → 30/10; tổng hợp 02/11; [bench-protocol.md](research/bench-protocol.md) mục 8, [plan.md](plan.md) §12 ý 28). 9 claim, 11 verdict, 9 đạt. H2a (nhãn trung bình posterior hơn tie điểm tốt nhất) còn giữ khi drift lớn hơn (c = 1,5; S1-H1), khi thêm các baseline không anchor B4a–d (S3-H1, ở R10, R0, Rm5), và với backbone thứ hai TCN (S4-H1). Lợi ích của bank tăng theo số giếng (S1-H2). Ở chế độ cycle-skip có điều khiển, hàm truyền đảo dấu như Hệ quả 3 dự đoán và bank hai mode hơn nhãn trung bình rõ rệt (S8). **Hai verdict trượt**, cả hai đều được dự đoán đạt: dưới sai mô hình rock physics, lợi ích H2a co xuống dưới ngưỡng (0,94 / 0,93). Dưới sai pha wavelet, posterior SMC quá tự tin (cov90 0,17 / 0,10) và lợi ích H2a mất hẳn (1,02 / 1,04). Chỉ trục drift đạt. Vì vậy không được nói H2a bền với sai mô hình nói chung. Code tổng hợp đã khoá khác lời phát biểu ở ba chỗ; verdict cuối theo đúng phát biểu do [36_bench_verdicts.py](../scripts/36_bench_verdicts.py) ghi, và cả hai cách đọc đều được báo cáo. Gói benchmark S7 (02/11; [37_bench_package.py](../scripts/37_bench_package.py), [benchmark/README.md](../benchmark/README.md)) có 630 task kèm truth ẩn và hash nội dung, cùng một lệnh chấm theo đúng luật đã khoá; selftest đạt. Chưa deposit Zenodo. Bank hai mode BK2 chứa warp thật nhưng không phải bank hiệu chỉnh theo Mệnh đề 4. Khi λ → 0, Hệ quả 3 cho transfer của nó là cos²(πfΔ), nhưng đo được gần 1 (0,92–1,00 ở N = 16): responsibility đã tái đăng ký nhãn. Kết quả và cách đọc này đã viết vào bài ngày 02/11 (mục 6.5, Thí nghiệm 3; mục cơ chế T2 là 6.4; [plan.md](plan.md) §12 ý 30).
Hình dung: muốn biết đôi giày mới giúp chạy nhanh hơn 1% hay không, cần một đồng hồ bấm giờ sai ít hơn 1% và nhiều lượt chạy. F3, Volve và Teapot đều chưa có đồng hồ đủ chính xác. Hình dung: muốn biết đôi giày mới giúp chạy nhanh hơn 1% hay không, cần một đồng hồ bấm giờ sai ít hơn 1% và nhiều lượt chạy. F3, Volve và Teapot đều chưa có đồng hồ đủ chính xác.
@@ -611,7 +613,8 @@ Hình dung: muốn biết đôi giày mới giúp chạy nhanh hơn 1% hay khôn
- "Calibrated uncertainty": mọi phương pháp đều under-cover. - "Calibrated uncertainty": mọi phương pháp đều under-cover.
- Gọi kết quả chỉ có trên synthetic là "khái quát ra field". Kết quả F3 và Volve không ủng hộ điều đó. - Gọi kết quả chỉ có trên synthetic là "khái quát ra field". Kết quả F3 và Volve không ủng hộ điều đó.
- Dùng Volve làm bằng chứng rằng RML "không hoạt động", hoặc dùng kết quả exploratory P4x làm bằng chứng nó "có hoạt động". - Dùng Volve làm bằng chứng rằng RML "không hoạt động", hoặc dùng kết quả exploratory P4x làm bằng chứng nó "có hoạt động".
- Nói rằng lợi ích thêm của bank vượt cận quần thể hoặc đã được giải thích. Nó chỉ vượt cận classical. Với cận Berkson, phần lớn lợi ích nằm trong cận, và nguồn lợi ích còn mở (T2). - Nói rằng lợi ích thêm của bank vượt cận quần thể hoặc đã được giải thích. Nó chỉ vượt cận classical. Với cận Berkson, lợi ích nằm trong cận. T2 (exploratory) gợi ý phần lớn lợi ích ở c = 1 là tăng cường nhãn, nhưng đó không phải claim xác nhận.
- Nói rằng nhãn trung bình posterior (H2a) bền với sai mô hình nói chung. S2-H1 chỉ đạt ở trục drift, trượt ở rock physics và pha wavelet.
- Dùng C1–C4 như một tiêu chí đã đăng ký trước: chúng được nêu sau khi cả hai field gate trượt. - Dùng C1–C4 như một tiêu chí đã đăng ký trước: chúng được nêu sau khi cả hai field gate trượt.
- Gọi marker của F3 là checkshot độc lập. - Gọi marker của F3 là checkshot độc lập.
- Bất kỳ kết quả nào có dính lựa chọn (dịch, checkpoint, hyperparameter) dựa trên nhãn test. - Bất kỳ kết quả nào có dính lựa chọn (dịch, checkpoint, hyperparameter) dựa trên nhãn test.

View File

@@ -29,7 +29,7 @@ Ngày 26/10/2026. Tài liệu này viết phần lý thuyết mà [plan.md](plan
**Giả thiết.** **Giả thiết.**
- (A1) Với mọi t, δ(t) độc lập với (X, y(·)) và có phân phối p_t. - (A1) Với mọi t, δ(t) độc lập với (X, y(·)) và có phân phối p_t.
- (A2) E[y(t)²] < ∞. - (A2) sup_t E[y(t)²] < ∞ (dưới giả thiết dừng thì tương đương E[y(t)²] < ∞; cần cho Fubini trong chứng minh).
**Mệnh đề 1.** Predictor tối ưu MSE cho nhãn quan sát là **Mệnh đề 1.** Predictor tối ưu MSE cho nhãn quan sát là
@@ -195,7 +195,7 @@ Gọi δ(t) = τ̄(t) − τ(t) là sai số của warp trung bình. Nếu poste
- 𝓛_w là log-likelihood Gaussian trên các cửa sổ. Với RML, áp cùng phép dịch cho mọi mẫu warp trong bank; lập luận không đổi. - 𝓛_w là log-likelihood Gaussian trên các cửa sổ. Với RML, áp cùng phép dịch cho mọi mẫu warp trong bank; lập luận không đổi.
**Giả thiết (B): lớp mô hình đóng dưới phép dịch đầu ra.** Với mỗi θ và mỗi β (bội của Δt, |β| ≤ β_max), tồn tại θ' sao cho μ_θ'(X) = T_β μ_θ(X) và σ_θ'(X) = T_β σ_θ(X). **Giả thiết (B): lớp mô hình đóng dưới phép dịch đầu ra.** Với mỗi θ và mỗi β (bội của Δt, |β| ≤ β_max), tồn tại θ' sao cho μ_θ'(X) = T_β μ_θ(X) và σ_θ'(X) = T_β σ_θ(X).
- Đúng chính xác khi lớp mô hình chứa phép dịch đầu ra. Ví dụ: mạng tích chập hoàn toàn có tầng cuối đủ rộng để dời tap kernel đi c mẫu. - Đúng chính xác khi lớp mô hình chứa phép dịch đầu ra. Ví dụ: mạng tích chập hoàn toàn có kernel tầng cuối rộng hơn phần trọng số nó dùng ít nhất β_max mẫu mỗi bên (sai khác chỉ ở mép cửa sổ).
- Đúng xấp xỉ với CNN–biGRU. - Đúng xấp xỉ với CNN–biGRU.
- Trong mọi trường hợp, chỉ đúng tới hiệu ứng biên của cửa sổ hữu hạn. - Trong mọi trường hợp, chỉ đúng tới hiệu ứng biên của cửa sổ hữu hạn.
@@ -213,6 +213,7 @@ Gọi δ(t) = τ̄(t) − τ(t) là sai số của warp trung bình. Nếu poste
\operatorname{sd}(\beta)\approx\Big(\frac{\sum_wK_w}{\sigma_a^2}+\frac{N}{\sigma_b^2}\Big)^{-1/2}\approx\frac{\sigma_a}{\sqrt{\sum_wK_w}} . \operatorname{sd}(\beta)\approx\Big(\frac{\sum_wK_w}{\sigma_a^2}+\frac{N}{\sigma_b^2}\Big)^{-1/2}\approx\frac{\sigma_a}{\sqrt{\sum_wK_w}} .
\] \]
- sd(β) ở đây là độ trải dọc ridge khi giữ các tham số khác cố định (nghịch đảo căn độ cong). Độ trải biên duyên, có lấy tích phân qua drift của từng giếng, không nhỏ hơn giá trị này (luật phương sai toàn phần).
- Ví dụ có anchor: 4 giếng × 16 anchor với σ_a = 7 ms cho sd(β) ≈ 0.9 ms. - Ví dụ có anchor: 4 giếng × 16 anchor với σ_a = 7 ms cho sd(β) ≈ 0.9 ms.
- Nếu chỉ có prior σ_b = 50 ms (giá trị trong protocol P2), sd(β) ≈ 50/√N: 35 ms với N = 2 và 12.5 ms với N = 16. - Nếu chỉ có prior σ_b = 50 ms (giá trị trong protocol P2), sd(β) ≈ 50/√N: 35 ms với N = 2 và 12.5 ms với N = 16.
- Cả hai đều lớn so với chu kỳ trong băng seismic. Theo nhận xét cuối mục 1.1, dịch chung β nhân thành phần tần số f của PCC với cos(2πfβ), và cos(2π · 20 Hz · 12.5 ms) = 0. - Cả hai đều lớn so với chu kỳ trong băng seismic. Theo nhận xét cuối mục 1.1, dịch chung β nhân thành phần tần số f của PCC với cos(2πfβ), và cos(2π · 20 Hz · 12.5 ms) = 0.
@@ -421,7 +422,7 @@ Giả thiết (A2) cho y và ỹ.
**Ý nghĩa.** **Ý nghĩa.**
- (a) là cấu trúc classical của mô hình sai số đo (sai số độc lập với giá trị thật); (b) là cấu trúc Berkson (sai số độc lập với giá trị được gán). Ở đây sai số nằm ở chỉ số thời gian của nhãn, và hai cấu trúc làm lệch predictor học được theo hai chiều ngược nhau: (a) làm mờ predictor và nới rộng phương sai học được; (b) làm sắc predictor và thu hẹp phương sai. - (a) là cấu trúc classical của mô hình sai số đo (sai số độc lập với giá trị thật); (b) là cấu trúc Berkson (sai số độc lập với giá trị được gán). Ở đây sai số nằm ở chỉ số thời gian của nhãn, và hai cấu trúc làm lệch predictor học được theo hai chiều ngược nhau: (a) làm mờ predictor và nới rộng phương sai học được; (b) làm sắc predictor và thu hẹp phương sai.
- Tie lấy bằng trung bình posterior, û = E[u* | D], là lý tưởng hoá tự nhiên của (b): E[u* − û | D] = 0 theo cách dựng, và trong mô hình tuyến tính–Gauss u* − û độc lập với D. Với offset b của warp, sai số thời gian bằng sai số posterior của b nên thừa hưởng tính chất này; với drift thì chỉ gần đúng, khi posterior hẹp. - Tie lấy bằng trung bình posterior, û = E[u* | D], là lý tưởng hoá tự nhiên của (b): E[u* − û | D] = 0 theo cách dựng, và trong mô hình tuyến tính–Gauss u* − û độc lập với D. Với offset b của warp, sai số thời gian bằng sai số posterior của b nên thừa hưởng tính chất này; với drift thì chỉ gần đúng, khi posterior hẹp.
- Tie khớp theo cách khác (ví dụ cực đại tương quan synthetic–seismic) có thể theo một trong hai cấu trúc hoặc không theo cấu trúc nào. Trên dữ liệu synthetic phân biệt được: với offset, classical nghĩa là Cov(b̂ − b*, b*) = 0, Berkson nghĩa là Cov(b* − b̂, b̂) = 0. - Tie khớp theo cách khác (ví dụ cực đại tương quan synthetic–seismic) có thể theo một trong hai cấu trúc hoặc không theo cấu trúc nào. Trên dữ liệu synthetic phân biệt được: với offset, classical kéo theo Cov(b̂ − b*, b*) = 0, Berkson kéo theo Cov(b* − b̂, b̂) = 0 (điều kiện cần, dùng làm phép kiểm ở T2).
### 6.2 Mệnh đề 4 (bank hiệu chỉnh) ### 6.2 Mệnh đề 4 (bank hiệu chỉnh)
@@ -433,12 +434,12 @@ Do đó giới hạn λ → 0 của RML (Bổ đề 2) có cùng nghiệm tối
**Lưu ý.** **Lưu ý.**
- Hiệu chỉnh là lý tưởng hoá; nó đúng với mẫu posterior chính xác khi S → ∞. Dưới giả thiết này, lấy biên theo posterior khử sai lệch quần thể của cả hai cấu trúc. - Hiệu chỉnh là lý tưởng hoá; nó đúng với mẫu posterior chính xác khi S → ∞. Dưới giả thiết này, lấy biên theo posterior khử sai lệch quần thể của cả hai cấu trúc.
- Warp trung bình không có tính chất này. B3d-Sa học nhãn tại warp trung bình ū, không phải nhãn trung bình. Khai triển y^u quanh ū: ȳ − y^{ū} = ½ Σ_s π_s (u_s − ū)ᵀ ∇²_u y^{ū} (u_s − ū) + O(‖u_s − ū‖³), nên hai nhãn chỉ trùng nhau tới bậc một theo độ trải posterior. Nếu sai số thời gian của warp trung bình theo (b), tối ưu quần thể của B3d-Sa bị làm sắc bởi 1/Q, còn của nhãn trung bình thì đúng. - Warp trung bình không có tính chất này. B3d-Sa học nhãn tại warp trung bình ū, không phải nhãn trung bình. Khai triển hình thức y^u quanh ū (u chứa hàm drift g): ȳ − y^{ū} = ½ Σ_s π_s (u_s − ū)ᵀ ∇²_u y^{ū} (u_s − ū) + O(Σ_s π_s ‖u_s − ū‖³), nên hai nhãn chỉ trùng nhau tới bậc một theo độ trải posterior. Nếu sai số thời gian của warp trung bình theo (b), tối ưu quần thể của B3d-Sa bị làm sắc bởi 1/Q, còn của nhãn trung bình thì đúng.
### 6.3 Hệ quả 3 (hai mode) và Nhận xét 1 (λ > 0) ### 6.3 Hệ quả 3 (hai mode) và Nhận xét 1 (λ > 0)
- **Hệ quả 3.** Cho sai số (δ dưới (a), ε dưới (b)) hằng trên cửa sổ, bằng ±Δ/2 với xác suất ½ mỗi bên, độc lập với X. Khi đó P = Q = cos(πfΔ), và dưới cả hai cấu trúc hệ số truyền từ m sang m̃ âm khi 1/(2Δ) < |f| < 3/(2Δ): ở đó nhãn điểm kéo mạng về sai dấu. Sai số Gauss cùng phương sai Δ²/4 có P = e^{−π²Δ²f²/2} > 0 ở mọi tần số. Nhãn trung bình của bank hiệu chỉnh có hệ số truyền 1. Dưới (a), bank gồm nhãn điểm dịch ±Δ/2 với trọng số bằng nhau có hệ số truyền cos²(πfΔ) ≥ 0. - **Hệ quả 3.** Cho sai số (δ dưới (a), ε dưới (b)) hằng trên cửa sổ, bằng ±Δ/2 với xác suất ½ mỗi bên, độc lập với (X, y) dưới (a) và với D dưới (b). Khi đó P = Q = cos(πfΔ), và dưới cả hai cấu trúc hệ số truyền từ m sang m̃ âm khi 1/(2Δ) < |f| < 3/(2Δ): ở đó nhãn điểm kéo mạng về sai dấu. Sai số Gauss cùng phương sai Δ²/4 có P = e^{−π²Δ²f²/2} > 0 ở mọi tần số. Nhãn trung bình của bank hiệu chỉnh có hệ số truyền 1. Dưới (a), lấy bank gồm nhãn điểm dịch ±Δ/2 với trọng số bằng nhau: tối ưu quần thể của MSE trên nhãn trung bình của nó, cũng là của RML trên bank này khi λ → 0, có hệ số truyền cos²(πfΔ) ≥ 0. Bank này chứa nhãn tại warp thật nhưng không hiệu chỉnh: trọng số ½–½ không phải xác suất posterior của hai thành viên (nếu hiệu chỉnh thì hệ số truyền là 1 theo Mệnh đề 4(a)). Dưới (b), m̂ = Q·m̂̃, nên hệ số truyền 1/Q chỉ xác định ở nơi Q ≠ 0; Q không có không điểm trong dải đảo, và tại không điểm của Q thì m̂ = 0.
- Đảo pha là tính chất của sai số đa mode mà một tóm tắt Gauss che mất. Nếu hai mode cách nhau một chu kỳ trội, Δ = 1/f_0, dải đảo là f_0/2 < |f| < 3f_0/2. Seismic F3 có đỉnh gần 60 Hz, nên dải đảo là 30–90 Hz. Bước nhảy chu kỳ cho sai số kiểu này; ở c = 2 posterior SMC đa mode. Trong ví dụ này, bank đặt tâm tại nhãn điểm chỉ khử đảo dấu bằng cách làm suy giảm thêm băng. - Đảo pha là tính chất của sai số đa mode mà một tóm tắt Gauss che mất. Nếu hai mode cách nhau một chu kỳ trội, Δ = 1/f_0, dải đảo đầu tiên là f_0/2 < |f| < 3f_0/2 (các dải đảo sau bắt đầu từ 5f_0/2). Seismic F3 có đỉnh gần 60 Hz, nên dải đảo là 30–90 Hz. Bước nhảy chu kỳ cho sai số kiểu này; ở c = 2 posterior SMC đa mode. Trong ví dụ này, bank đặt tâm tại nhãn điểm chỉ khử đảo dấu bằng cách làm suy giảm thêm băng.
- **Nhận xét 1.** Mệnh đề 4 chỉ nói về giới hạn λ → 0. Khai triển hàm sinh cumulant: RML_λ = −(1/n)[Σ_s π_s ℓ_s + (λ/2) Var_π(ℓ) + O(λ²)]. Số hạng thứ hai thưởng cho predictor khớp một số thành viên của bank tốt hơn hẳn các thành viên khác. Với λ > 0, responsibilities của Bổ đề 3 dồn trọng số về các thành viên khớp với mạng hiện tại, tức một kiểu tái đăng ký ngầm, và nghiệm tối ưu quần thể nói chung không còn là (m, Var(y | X)). - **Nhận xét 1.** Mệnh đề 4 chỉ nói về giới hạn λ → 0. Khai triển hàm sinh cumulant: RML_λ = −(1/n)[Σ_s π_s ℓ_s + (λ/2) Var_π(ℓ) + O(λ²)]. Số hạng thứ hai thưởng cho predictor khớp một số thành viên của bank tốt hơn hẳn các thành viên khác. Với λ > 0, responsibilities của Bổ đề 3 dồn trọng số về các thành viên khớp với mạng hiện tại, tức một kiểu tái đăng ký ngầm, và nghiệm tối ưu quần thể nói chung không còn là (m, Var(y | X)).
### 6.4 Bank được lợi tối đa bao nhiêu (ρ*) ### 6.4 Bank được lợi tối đa bao nhiêu (ρ*)
@@ -458,12 +459,12 @@ Do đó giới hạn λ → 0 của RML (Bổ đề 2) có cùng nghiệm tối
Ký hiệu: phương pháp j dự báo trung bình μ và phương sai s² ở mọi mẫu test; v_j = E s², w_j = E(y − μ)², ξ_j = v_j / w_j, kỳ vọng lấy trên mẫu test. ξ = 1 nghĩa là phương sai dự báo khớp sai số bình phương trung bình. `scripts/30_t4_coverage.py` ghi ξ ở cột `kappa`. Ký hiệu: phương pháp j dự báo trung bình μ và phương sai s² ở mọi mẫu test; v_j = E s², w_j = E(y − μ)², ξ_j = v_j / w_j, kỳ vọng lấy trên mẫu test. ξ = 1 nghĩa là phương sai dự báo khớp sai số bình phương trung bình. `scripts/30_t4_coverage.py` ghi ξ ở cột `kappa`.
- (a) Với mọi j và O: ξ_j − ξ_O = (Δv − ξ_O Δw) / w_j, với Δv = v_j − v_O, Δw = w_j − w_O. - (a) Với mọi j và O: ξ_j − ξ_O = (Δv − ξ_O Δw) / w_j, với Δv = v_j − v_O, Δw = w_j − w_O.
- (b) Cho y dừng và (A1) với P thực, 0 ≤ P ≤ 1. So nhãn điểm tại tối ưu quần thể (μ = m̃, s² = Var(ỹ | X)) với Oracle tại tối ưu (μ = m, s² = Var(y | X)). Khi đó ξ_O = 1 và ξ_j − ξ_O = (2 / w_j) ∫ P(1 − P) S_m df ≥ 0. - (b) Cho m và y đồng dừng, và (A1) với p_t ≡ p, P thực, 0 ≤ P ≤ 1. So nhãn điểm tại tối ưu quần thể (μ = m̃, s² = Var(ỹ | X)) với Oracle tại tối ưu (μ = m, s² = Var(y | X)). Khi đó ξ_O = 1 và ξ_j − ξ_O = (2 / w_j) ∫ P(1 − P) S_m df ≥ 0.
- (c) Dưới cấu trúc (b) của Mệnh đề 3, với q_t không phụ thuộc t và y dừng, nhãn điểm tại tối ưu quần thể có ξ_j ≤ 1. Bank hiệu chỉnh có ξ_j = 1. - (c) Dưới cấu trúc (b) của Mệnh đề 3, với q_t không phụ thuộc t và y dừng, nhãn điểm tại tối ưu quần thể có ξ_j ≤ 1. Bank hiệu chỉnh tại tối ưu quần thể λ → 0 của Mệnh đề 4 có ξ = 1.
- Nếu y − μ = sZ/√ξ với Z chuẩn tắc độc lập với s, khoảng μ ± z·s phủ với xác suất 2Φ(z√ξ) − 1, tăng theo ξ. - Nếu y − μ = sZ/√ξ với Z chuẩn tắc độc lập với s, khoảng μ ± z·s phủ với xác suất 2Φ(z√ξ) − 1, tăng theo ξ.
**Ý nghĩa và T4 (post hoc, bài mục 6.3, Bảng `tab:t4`).** **Ý nghĩa và T4 (post hoc, bài mục 6.3, Bảng `tab:t4`).**
- (a) là đồng nhất thức, đúng cho mọi ensemble hữu hạn: j phủ nhiều hơn Oracle khi phương sai dự báo vượt Oracle quá ξ_O lần phần sai số bình phương dư. (b) và (c) là giới hạn quần thể: classical làm rộng khoảng của nhãn điểm, Berkson làm hẹp, bank hiệu chỉnh khớp Oracle. - (a) là đồng nhất thức, đúng cho mọi ensemble hữu hạn: j phủ nhiều hơn Oracle khi phương sai dự báo vượt Oracle quá ξ_O lần phần sai số bình phương dư. (b) và (c) là giới hạn quần thể (bank ở λ → 0): classical làm rộng khoảng của nhãn điểm, Berkson làm hẹp, bank hiệu chỉnh khớp Oracle.
- Ở ô R10, c = 1, N = 16, mọi ensemble đều quá hẹp: ξ là 0,19 ở Oracle và tối đa 0,66 (B5). Vì ξ_O nhỏ, chỉ cần dư một chút phương sai là phủ nhiều hơn Oracle. - Ở ô R10, c = 1, N = 16, mọi ensemble đều quá hẹp: ξ là 0,19 ở Oracle và tối đa 0,66 (B5). Vì ξ_O nhỏ, chỉ cần dư một chút phương sai là phủ nhiều hơn Oracle.
- Độ dài huấn luyện và nguồn nhãn lẫn nhau: B3c-R học 500 vòng lặp (như Oracle) đạt cùng ξ với B3d-Sa ở 250 vòng. Trên dev của Thí nghiệm 1, coverage90 của Oracle đơn lẻ giảm 0,47 → 0,23 → 0,10 sau 125/500/2000 vòng lặp. Vì vậy (b) và (c) **chưa được kiểm**. Không claim hiệu chỉnh. - Độ dài huấn luyện và nguồn nhãn lẫn nhau: B3c-R học 500 vòng lặp (như Oracle) đạt cùng ξ với B3d-Sa ở 250 vòng. Trên dev của Thí nghiệm 1, coverage90 của Oracle đơn lẻ giảm 0,47 → 0,23 → 0,10 sau 125/500/2000 vòng lặp. Vì vậy (b) và (c) **chưa được kiểm**. Không claim hiệu chỉnh.
@@ -472,14 +473,14 @@ Ký hiệu: phương pháp j dự báo trung bình μ và phương sai s² ở m
Thiết lập: reference ở giếng blind là y_ref(t) = y(t + ε_r), với ε_r hằng trên cửa sổ, độc lập với dự đoán ŷ và với nhãn thật y, có hàm đặc trưng Q_r; ŷ và y đồng dừng với phổ chéo S_{ŷy}. Thiết lập: reference ở giếng blind là y_ref(t) = y(t + ε_r), với ε_r hằng trên cửa sổ, độc lập với dự đoán ŷ và với nhãn thật y, có hàm đặc trưng Q_r; ŷ và y đồng dừng với phổ chéo S_{ŷy}.
- **Mệnh đề 6.** E|B(ŷ − y_ref)|² = E|B(ŷ − y)|² + 2 ∫_{|f|≥f_c} Re[(1 − Q_r(f)) S_{ŷy}(f)] df. - **Mệnh đề 6.** E|B(ŷ − y_ref)|² = E|B(ŷ − y)|² + 2 ∫_{|f|≥f_c} Re[(1 − Q_r(f)) S_{ŷy}(f)] df.
- Với sai số đối xứng, 0 ≤ 1 − Q_r ≤ 2, nên reference phạt sự khớp trong băng với nhãn thật. Số hạng thêm phụ thuộc phương pháp, nên có thể đảo thứ hạng hai phương pháp, và không triệt tiêu khi lấy trung bình qua giếng: thêm giếng blind giảm phương sai của phép so sánh, không giảm độ lệch. - Với sai số đối xứng, 0 ≤ 1 − Q_r ≤ 2, nên reference phạt sự khớp trong băng với nhãn thật. Số hạng thêm phụ thuộc phương pháp, nên có thể đảo thứ hạng hai phương pháp, và không triệt tiêu khi lấy trung bình qua giếng: thêm giếng blind giảm phương sai của phép so sánh, không giảm độ lệch.
- **Hệ quả 4.** Với hai phương pháp A và B, gọi G là lợi thế band MSE thật của A và G_r là lợi thế đo với y_ref. Khi đó G_r − G = 2 ∫_{|f|≥f_c} Re[(1 − Q_r)(S_{ŷ_B y} − S_{ŷ_A y})] df. - **Hệ quả 4.** Với hai phương pháp 1 và 2 (bài đổi tên từ A, B ngày 02/11/2026 vì B là toán tử băng), gọi G là lợi thế band MSE thật của phương pháp 1 và G_r là lợi thế đo với y_ref. Khi đó G_r − G = 2 ∫_{|f|≥f_c} Re[(1 − Q_r)(S_{ŷ_2 y} − S_{ŷ_1 y})] df.
- Lấy ŷ_A = Hm và ŷ_B = HPm với các bộ lọc thực 0 ≤ H, P ≤ 1 (A học Oracle, B học tối ưu bị mờ của (a), cả hai bị co bởi cùng hệ số mẫu hữu hạn H). Khi đó G = ∫ H(1 − P)[2 − H(1 + P)] S_m df ≥ 0 và G_r = ∫ H(1 − P)[2Q_r − H(1 + P)] S_m df. - Lấy ŷ_1 = Hm và ŷ_2 = HPm với các bộ lọc thực 0 ≤ H, P ≤ 1 (phương pháp 1 học Oracle, phương pháp 2 học tối ưu bị mờ của (a), cả hai bị co bởi cùng hệ số mẫu hữu hạn H). Khi đó G = ∫ H(1 − P)[2 − H(1 + P)] S_m df ≥ 0 và G_r = ∫ H(1 − P)[2Q_r − H(1 + P)] S_m df.
- Với H = 1 và sai số Gauss trung bình 0 có độ lệch chuẩn σ (tie của nhãn điểm) và σ_r (reference): 2Q_r − 1 − P = 2π²f²(σ² − 2σ_r²) + O(f⁴). Ở bậc dẫn, **lợi thế đo được cùng dấu với lợi thế thật chỉ khi σ_r < σ/√2**. - Với H = 1 và sai số Gauss trung bình 0 có độ lệch chuẩn σ (tie của nhãn điểm) và σ_r (reference): 2Q_r − 1 − P = 2π²f²(σ² − 2σ_r²) + O(f⁴). Vì vậy **lợi thế đo được chỉ có thể cùng dấu với lợi thế thật khi σ_r < σ/√2**. Điều kiện này cần ở mọi bậc, không chỉ bậc dẫn: nếu σ_r ≥ σ/√2 thì 2Q_r − 1 − P ≤ −(1 − e^{−π²σ²f²})² ≤ 0 ở mọi f, nên G_r ≤ 0 (H = 1). Nó không đủ: điểm đổi dấu thật nằm dưới σ/√2 (kiểm độc lập 02/11/2026, docs/plan.md §12 mục 32).
- Co rút nới điều kiện này, vì 2Q_r − H(1 + P) tăng khi H giảm. Nếu B quá sắc, như dưới (b), với ŷ_B = HKm và K ≥ 1, thì G_r − G = 2 ∫ H(K − 1)(1 − Q_r) S_m df ≥ 0: reference phóng đại lợi thế của A. - Co rút nới điều kiện này, vì 2Q_r − H(1 + P) tăng khi H giảm. Nếu phương pháp 2 quá sắc, như dưới (b), với ŷ_2 = HKm và K ≥ 1, thì G_r − G = 2 ∫ H(K − 1)(1 − Q_r) S_m df ≥ 0: reference phóng đại lợi thế của phương pháp 1.
- Độc lập giữa ε_r và dự đoán hợp lý với reference từ checkshot hoặc VSP. Reference tie bằng khớp synthetic–seismic phụ thuộc cùng seismic với dự đoán, và sai số của nó thêm một số hạng hiệp phương sai vào công thức của Mệnh đề 6. - Độc lập giữa ε_r và dự đoán hợp lý với reference từ checkshot hoặc VSP. Reference tie bằng khớp synthetic–seismic phụ thuộc cùng seismic với dự đoán, và sai số của nó thêm một số hạng hiệp phương sai vào công thức của Mệnh đề 6.
**Kiểm bằng mô phỏng (T3, exploratory; bài mục 6.5, Bảng `tab:t3`; `scripts/27_t3_power.py`).** **Kiểm bằng mô phỏng (T3, exploratory; bài mục 6.6 (trước 02/11/2026 là 6.5), Bảng `tab:t3`; `scripts/27_t3_power.py`).**
- Ở ba ô N = 16, tỉ số band RMSE trung vị M2-Sa/đối thủ cắt 1 ở σ_ref = 3,6–4,3 ms, so với σ/√2 = 3,0/4,1/5,1 ms (sai số warp RMS của B3c-R trên giếng train là 4,2/5,8/7,3 ms ở R10/R0/Rm5): cùng thứ tự, lệch không quá 1 ms. - Ở ba ô N = 16, tỉ số band RMSE trung vị M2-Sa/đối thủ cắt 1 ở σ_ref = 3,6–4,3 ms, so với σ/√2 = 3,0/4,1/5,1 ms (sai số warp RMS của B3c-R trên giếng train là 4,2/5,8/7,3 ms ở R10/R0/Rm5): cùng thứ tự, lệch không quá 1 ms. Nội suy tuyến tính cho 3,6/3,8/4,3 ms: dưới σ/√2 ở R0 và Rm5, trên 0,6 ms ở R10; điều đó không mâu thuẫn với Hệ quả 4 vì co rút (H < 1) nới điều kiện và M2-Sa không phải Oracle.
- Với reference chính xác, sign test một phía (α = 0,05) đạt power 0,8 với 5–18 giếng blind ở 5/6 ô (ô R10, N = 4 không đạt vì ICC 0,45). Ở σ_ref = 1 ms, bốn ô cần 11–30 giếng; ở 2 ms chỉ R0 còn trong 40 giếng (23 và 37); từ 3 ms trở lên không ô nào đạt. - Với reference chính xác, sign test một phía (α = 0,05) đạt power 0,8 với 5–18 giếng blind ở 5/6 ô (ô R10, N = 4 không đạt vì ICC 0,45). Ở σ_ref = 1 ms, bốn ô cần 11–30 giếng; ở 2 ms chỉ R0 còn trong 40 giếng (23 và 37); từ 3 ms trở lên không ô nào đạt.
- Luật k-of-n của hai gate field không phải phép kiểm: khi không có khác biệt thật và giếng độc lập, nó vẫn đạt với xác suất 5/16 = 0,31 (n = 4) và 7/64 = 0,11 (n = 6). - Luật k-of-n của hai gate field không phải phép kiểm: khi không có khác biệt thật và giếng độc lập, nó vẫn đạt với xác suất 5/16 = 0,31 (n = 4) và 7/64 = 0,11 (n = 6).

View File

@@ -195,3 +195,11 @@ run_id,parent,name,status,exit_code,start,end,wall_s,wall,device,git,dirty,code_
20261030-015331_bench_train_S1_cuda1,,bench_train_S1_cuda1,interrupted,-15,2026-10-30T01:53:31+00:00,2026-10-30T01:58:21+00:00,289.6,0:04:50,cuda:1,381b5ffb0620,True,ba88b1f22934cb8d,runlog,.venv/bin/python scripts/34_run_bench.py train --device cuda:1 --workers 16 --threads 2 --gpu-mem-gb 2 --studies S1 --regimes R0h 20261030-015331_bench_train_S1_cuda1,,bench_train_S1_cuda1,interrupted,-15,2026-10-30T01:53:31+00:00,2026-10-30T01:58:21+00:00,289.6,0:04:50,cuda:1,381b5ffb0620,True,ba88b1f22934cb8d,runlog,.venv/bin/python scripts/34_run_bench.py train --device cuda:1 --workers 16 --threads 2 --gpu-mem-gb 2 --studies S1 --regimes R0h
20261030-015840_bench_posterior_S1_cuda1,,bench_posterior_S1_cuda1,ok,0,2026-10-30T01:58:40+00:00,2026-10-30T01:58:53+00:00,13.7,0:00:14,cuda:1,381b5ffb0620,True,ba88b1f22934cb8d,runlog,.venv/bin/python scripts/34_run_bench.py posterior --device cuda:1 --workers 16 --threads 2 --gpu-mem-gb 2 --studies S1 --regimes R0h 20261030-015840_bench_posterior_S1_cuda1,,bench_posterior_S1_cuda1,ok,0,2026-10-30T01:58:40+00:00,2026-10-30T01:58:53+00:00,13.7,0:00:14,cuda:1,381b5ffb0620,True,ba88b1f22934cb8d,runlog,.venv/bin/python scripts/34_run_bench.py posterior --device cuda:1 --workers 16 --threads 2 --gpu-mem-gb 2 --studies S1 --regimes R0h
20261030-015854_bench_train_S1_cuda1,,bench_train_S1_cuda1,ok,0,2026-10-30T01:58:54+00:00,2026-10-30T02:16:17+00:00,1043.7,0:17:24,cuda:1,381b5ffb0620,True,ba88b1f22934cb8d,runlog,.venv/bin/python scripts/34_run_bench.py train --device cuda:1 --workers 16 --threads 2 --gpu-mem-gb 2 --studies S1 --regimes R0h 20261030-015854_bench_train_S1_cuda1,,bench_train_S1_cuda1,ok,0,2026-10-30T01:58:54+00:00,2026-10-30T02:16:17+00:00,1043.7,0:17:24,cuda:1,381b5ffb0620,True,ba88b1f22934cb8d,runlog,.venv/bin/python scripts/34_run_bench.py train --device cuda:1 --workers 16 --threads 2 --gpu-mem-gb 2 --studies S1 --regimes R0h
20261102-020220_bench_summarize,,bench_summarize,ok,0,2026-11-02T02:02:20+00:00,2026-11-02T02:02:49+00:00,29.4,0:00:29,cuda:0,2e4f618947c4,True,ba88b1f22934cb8d,runlog,.venv/bin/python scripts/34_run_bench.py summarize --device cuda:0 --workers 4 --threads 2 --gpu-mem-gb 6 --studies S1 S2 S3 S4 S8
20261102-020738_bench_verdicts,,bench_verdicts,ok,0,2026-11-02T02:07:38+00:00,2026-11-02T02:07:47+00:00,8.7,0:00:09,,2e4f618947c4,True,f7a25a280cf5e0e6,runlog,/home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/36_bench_verdicts.py
20261102-020804_bench_verdicts,,bench_verdicts,ok,0,2026-11-02T02:08:04+00:00,2026-11-02T02:08:13+00:00,9.0,0:00:09,,2e4f618947c4,True,862a5c2f37ff3586,runlog,/home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/36_bench_verdicts.py
20261102-022806_bench_package_tables,,bench_package_tables,ok,0,2026-11-02T02:28:06+00:00,2026-11-02T02:28:24+00:00,18.4,0:00:18,,2e4f618947c4,True,0ae7d821416ef8af,runlog,/home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/37_bench_package.py tables
20261102-022758_bench_package_generate,,bench_package_generate,ok,0,2026-11-02T02:27:58+00:00,2026-11-02T02:30:19+00:00,140.9,0:02:21,,2e4f618947c4,True,0ae7d821416ef8af,runlog,/home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/37_bench_package.py generate
20261102-023050_bench_package_selftest,,bench_package_selftest,failed,1,2026-11-02T02:30:50+00:00,2026-11-02T02:31:01+00:00,10.3,0:00:10,,2e4f618947c4,True,0ae7d821416ef8af,runlog,/home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/37_bench_package.py selftest
20261102-023112_bench_package_selftest,,bench_package_selftest,ok,0,2026-11-02T02:31:12+00:00,2026-11-02T02:31:25+00:00,12.9,0:00:13,,2e4f618947c4,True,c03b0775b199945d,runlog,/home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/37_bench_package.py selftest
20261102-023145_bench_package_regenerate,,bench_package_regenerate,ok,0,2026-11-02T02:31:45+00:00,2026-11-02T02:33:52+00:00,127.0,0:02:07,,2e4f618947c4,True,c03b0775b199945d,runlog,/home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/37_bench_package.py generate
1 run_id parent name status exit_code start end wall_s wall device git dirty code_sha source cmd
195 20261030-015331_bench_train_S1_cuda1 bench_train_S1_cuda1 interrupted -15 2026-10-30T01:53:31+00:00 2026-10-30T01:58:21+00:00 289.6 0:04:50 cuda:1 381b5ffb0620 True ba88b1f22934cb8d runlog .venv/bin/python scripts/34_run_bench.py train --device cuda:1 --workers 16 --threads 2 --gpu-mem-gb 2 --studies S1 --regimes R0h
196 20261030-015840_bench_posterior_S1_cuda1 bench_posterior_S1_cuda1 ok 0 2026-10-30T01:58:40+00:00 2026-10-30T01:58:53+00:00 13.7 0:00:14 cuda:1 381b5ffb0620 True ba88b1f22934cb8d runlog .venv/bin/python scripts/34_run_bench.py posterior --device cuda:1 --workers 16 --threads 2 --gpu-mem-gb 2 --studies S1 --regimes R0h
197 20261030-015854_bench_train_S1_cuda1 bench_train_S1_cuda1 ok 0 2026-10-30T01:58:54+00:00 2026-10-30T02:16:17+00:00 1043.7 0:17:24 cuda:1 381b5ffb0620 True ba88b1f22934cb8d runlog .venv/bin/python scripts/34_run_bench.py train --device cuda:1 --workers 16 --threads 2 --gpu-mem-gb 2 --studies S1 --regimes R0h
198 20261102-020220_bench_summarize bench_summarize ok 0 2026-11-02T02:02:20+00:00 2026-11-02T02:02:49+00:00 29.4 0:00:29 cuda:0 2e4f618947c4 True ba88b1f22934cb8d runlog .venv/bin/python scripts/34_run_bench.py summarize --device cuda:0 --workers 4 --threads 2 --gpu-mem-gb 6 --studies S1 S2 S3 S4 S8
199 20261102-020738_bench_verdicts bench_verdicts ok 0 2026-11-02T02:07:38+00:00 2026-11-02T02:07:47+00:00 8.7 0:00:09 2e4f618947c4 True f7a25a280cf5e0e6 runlog /home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/36_bench_verdicts.py
200 20261102-020804_bench_verdicts bench_verdicts ok 0 2026-11-02T02:08:04+00:00 2026-11-02T02:08:13+00:00 9.0 0:00:09 2e4f618947c4 True 862a5c2f37ff3586 runlog /home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/36_bench_verdicts.py
201 20261102-022806_bench_package_tables bench_package_tables ok 0 2026-11-02T02:28:06+00:00 2026-11-02T02:28:24+00:00 18.4 0:00:18 2e4f618947c4 True 0ae7d821416ef8af runlog /home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/37_bench_package.py tables
202 20261102-022758_bench_package_generate bench_package_generate ok 0 2026-11-02T02:27:58+00:00 2026-11-02T02:30:19+00:00 140.9 0:02:21 2e4f618947c4 True 0ae7d821416ef8af runlog /home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/37_bench_package.py generate
203 20261102-023050_bench_package_selftest bench_package_selftest failed 1 2026-11-02T02:30:50+00:00 2026-11-02T02:31:01+00:00 10.3 0:00:10 2e4f618947c4 True 0ae7d821416ef8af runlog /home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/37_bench_package.py selftest
204 20261102-023112_bench_package_selftest bench_package_selftest ok 0 2026-11-02T02:31:12+00:00 2026-11-02T02:31:25+00:00 12.9 0:00:13 2e4f618947c4 True c03b0775b199945d runlog /home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/37_bench_package.py selftest
205 20261102-023145_bench_package_regenerate bench_package_regenerate ok 0 2026-11-02T02:31:45+00:00 2026-11-02T02:33:52+00:00 127.0 0:02:07 2e4f618947c4 True c03b0775b199945d runlog /home/jovyan/lamlvh/ML-Porosity/.venv/bin/python scripts/37_bench_package.py generate

View File

@@ -10,31 +10,45 @@ Red text (`\todo`, `\todoblock`, `\figplaceholder`) marks parts that are not rea
Search for them with `grep -n 'todo\|figplaceholder' sections/*.tex`. Search for them with `grep -n 'todo\|figplaceholder' sections/*.tex`.
All figures in `figures/` are produced by `python scripts/22_paper_figures.py` (from the repo root, All figures in `figures/` are produced by `python scripts/22_paper_figures.py` (from the repo root,
with the `.venv`); it reads only the locked summaries listed below. with the `.venv`), except `bench_s1.pdf` and `bench_s8.pdf` (Experiment 3), which come from
`python scripts/38_bench_figures.py`; both read only the locked summaries listed below.
## Where the numbers come from ## Where the numbers come from
| Paper element | Source | | Paper element | Source |
|---|---| |---|---|
| Abstract, Sec. 1 (findings paragraph), Sec. 8, `highlights.txt` | Rows below: H2a and σ_a from `tab:h2a`/`tab:sigmaa`; bank gain and bounds (registered (a), post hoc (b)) from `tab:h2b` and `outputs/p2r/posthoc/{bound.csv,meta.json}`; wells needed from `outputs/t3/nstar.csv`; field results from App. B; Teapot counts from Sec. 6.6 sources | | Abstract, Sec. 1 (findings paragraph), Sec. 8, `highlights.txt` | Rows below: H2a and σ_a from `tab:h2a`/`tab:sigmaa`; bank gain and bounds (registered (a), post hoc (b)) from `tab:h2b` and `outputs/p2r/posthoc/{bound.csv,meta.json}`; wells needed from `outputs/t3/nstar.csv`; field results from App. B; Teapot counts from Sec. 6.7 sources; Experiment 3 (9/11 verdicts, failures, two-mode reversal) from the Sec. 6.5 rows |
| Sec. 1 (F3 drift 14–66 ms, 46 ms, 36 ms; dominant period 17–20 ms) | `outputs/td_qc.csv`, `outputs/tie_qc.csv`, `docs/plan.md` §1.2 | | Sec. 1 (F3 drift 14–66 ms, 46 ms, 36 ms; dominant period 17–20 ms) | `outputs/td_qc.csv`, `outputs/tie_qc.csv`, `docs/plan.md` §1.2 |
| Sec. 2 (label noise and errors in variables; Table `tab:positioning`) | `refs.bib` `annote` fields: Mnih & Hinton (2012) read in full on 2026-10-29 (Secs. 5, 6.1, 6.3); Balakrishnan (1962) metadata from Crossref only, cited for the general statement; abstract-only entries flagged in the table | | Sec. 2 (label noise and errors in variables; Table `tab:positioning`) | `refs.bib` `annote` fields: Mnih & Hinton (2012) read in full on 2026-10-29 (Secs. 5, 6.1, 6.3); Balakrishnan (1962) metadata from Crossref only, cited for the general statement; abstract-only entries flagged in the table. Preliminary novelty scan of 2026-11-02 (`docs/plan.md` §12 item 31): Herrera & van der Baan (2014), da Costa Silva et al. (2026, Autotie) and Castagna et al. (2026) from their abstracts (OpenAlex), metadata from Crossref (Castagna et al. later read in full, 2026-11-02: timing-error remarks in their Discussion, `docs/plan.md` §12 item 33); the label source of Sukar et al. (2026) from the full text in `refs/` (Sec. 3, "Data preparation"). Full texts obtained on 2026-11-02 (`docs/plan.md` §12 item 33): Lim et al. (2025, AWSM; 44 wells, median/minimum-misfit models, TD posterior not used downstream), Lim & Cardona (2025, BootNet), Li, Grana & Liu (2024, P05; deterministic tie in the field case), Guillon et al. (2020; tolerance in evaluation only) and Rizzuti et al. (2024, 2025; wavelet treated as known, future-work statement); their ᵃ markers were removed |
| Sec. 3, Table `tab:audit` (TD drift, label audit) | `outputs/td_qc.csv`, `outputs/tie_qc.csv`, `outputs/marker_vs_horizon.csv`, `docs/plan.md` | | Sec. 3, Table `tab:audit` (TD drift, label audit) | `outputs/td_qc.csv`, `outputs/tie_qc.csv`, `outputs/marker_vs_horizon.csv`, `docs/plan.md` |
| Sec. 3.2, paragraph "Misspecification (Experiment 3)" (presets, scale factors, Q 80 peak shift, model error 0.23 nominal and 1.08–1.93 for the presets, L1 levels above the declared band, minphase 0.25 candidate, Rm5 null 1.78× and 0.22–0.34) | Presets: `configs/protocol_bench.yaml` (`studies.S2.presets`) and the `misspec_presets` block of `configs/d2_synth_bench.yaml`; generator `ml_porosity/data/synth_d2.py` (`misspec=`); level choice on dev 902–905 and the model-error table: `docs/research/bench-protocol.md` (S2 level table and decisions) and `docs/research/bench-generator.md`, QC from `scripts/33_bench_generator_qc.py` |
| Sec. 3.3 (Volve data: licence, label check, deviated wells, cube, time–depth, anchors, labels) | `outputs/volve/volve_wells_summary.json`, `outputs/volve/{summary.json,anchors.csv,pick_vs_horizon.csv,pick_vs_checkshot.csv,horizon_lag.csv}`, `docs/research/volve-inventory.md`, `docs/plan.md` §12 items 7 and 18 | | Sec. 3.3 (Volve data: licence, label check, deviated wells, cube, time–depth, anchors, labels) | `outputs/volve/volve_wells_summary.json`, `outputs/volve/{summary.json,anchors.csv,pick_vs_horizon.csv,pick_vs_checkshot.csv,horizon_lag.csv}`, `docs/research/volve-inventory.md`, `docs/plan.md` §12 items 7 and 18 |
| Sec. 4, Table `tab:h1`, Fig. `fig:h1` | `outputs/p2/summary/main/h1.csv`, `docs/theory.md` | | Sec. 4, Table `tab:h1`, Fig. `fig:h1` | `outputs/p2/summary/main/h1.csv`, `docs/theory.md` |
| Sec. 4.3–4.5 (Propositions 3–6, Corollaries 3–4, Remark 1, ρ*) | Analytic; proofs in App. A; Vietnamese statements in `docs/theory.md` §6. The factors 1.10 and 1.77 are e^{4π²σ²f²} at σ = 2 ms, f = 25 and 60 Hz (`meta.json` `transfer_ratio_exp_4pi2s2f2`); 71–73% coherent power below 25 Hz, the 67–72 Hz f⁴-weighted median and the (b)/(a) integral ratios 1.5–1.7, 2.1–2.6 and 3.3–4.6 are from `outputs/p2r/posthoc/meta.json` `n16_spectra` (coherent part: `coherent_share_below_25hz`, `f4_weighted_median_hz.coherent`; integral ratios span the Oracle and coherent spectra over the five regimes); 30–90 Hz uses the ~60 Hz F3 peak of Sec. 3.1 | | Sec. 4.3–4.5 (Propositions 3–6, Corollaries 3–4, Remark 1, ρ*) | Analytic; proofs in App. A; Vietnamese statements in `docs/theory.md` §6. The factors 1.10 and 1.77 are e^{4π²σ²f²} at σ = 2 ms, f = 25 and 60 Hz (`meta.json` `transfer_ratio_exp_4pi2s2f2`); 71–73% coherent power below 25 Hz, the 67–72 Hz f⁴-weighted median and the (b)/(a) integral ratios 1.5–1.7, 2.1–2.6 and 3.3–4.6 are from `outputs/p2r/posthoc/meta.json` `n16_spectra` (coherent part: `coherent_share_below_25hz`, `f4_weighted_median_hz.coherent`; integral ratios span the Oracle and coherent spectra over the five regimes); 30–90 Hz uses the ~60 Hz F3 peak of Sec. 3.1 |
| Sec. 5 (prior fit on F3, LOAO, type-II σ_a) | `docs/plan.md` §12, `docs/theory.md` | | Sec. 5 (prior fit on F3, LOAO, type-II σ_a) | `docs/plan.md` §12, `docs/theory.md` |
| Sec. 5.6 (TCN backbone, budget 125 on dev 902–905), Table `tab:methods` (benchmark additions Ctl-GP, PM2, BK2, HM2, -TCN) | `configs/protocol_bench.yaml` (`methods`, `training.budgets`, `training.budgets_tcn`, `training.budget_candidates`), `ml_porosity/benchmark/`, `docs/research/bench-protocol.md` (TCN budget selection; log `logs/bench_dev_budgets_tcn.out`) |
| Sec. 6.1, Table `tab:p2`, Fig. `fig:p2phase` | `outputs/p2/summary/main/{summary.md,methods.csv}` | | Sec. 6.1, Table `tab:p2`, Fig. `fig:p2phase` | `outputs/p2/summary/main/{summary.md,methods.csv}` |
| Sec. 6.2 (diagnosis, deviation) | `docs/plan.md` §12 items 11–14 | | Sec. 6.2 (diagnosis, deviation) | `docs/plan.md` §12 items 11–14 |
| Sec. 6.3, Tables `tab:h2a`, `tab:sigmaa`, `tab:h2b`; Figs. `fig:h2b`, `fig:p2rgrid` | `outputs/p2r/summary/{summary.md,verdict.json}`; σ_post and warp RMSE from `outputs/p2r/summary/sigma_post.csv` | | Sec. 6.3, Tables `tab:h2a`, `tab:sigmaa`, `tab:h2b`; Figs. `fig:h2b`, `fig:p2rgrid` | `outputs/p2r/summary/{summary.md,verdict.json}`; σ_post and warp RMSE from `outputs/p2r/summary/sigma_post.csv` |
| Sec. 6.3, column 1/B_b of `tab:h2b` (Berkson bound at σ_post; bounds at the warp error; 60 Hz and cross-spectral variants; exact (a) bound 0.481 at σ_post for R10tb c = 2; Oracle/B3d-Sa ratios; share of the gap closed; 6 ms grid edge; post hoc) | `outputs/p2r/posthoc/{bound.csv,blur_ab.csv,meta.json}` (counts in `meta.json` `n16_wide`), written by `python scripts/31_p2r_posthoc.py` (about 6 min) from the registered summaries and the Oracle test predictions in `outputs/p2r/train/<regime>/cells/*.npz` | | Sec. 6.3, column 1/B_b of `tab:h2b` (Berkson bound at σ_post; bounds at the warp error; 60 Hz and cross-spectral variants; exact (a) bound 0.481 at σ_post for R10tb c = 2; Oracle/B3d-Sa ratios; share of the gap closed; 6 ms grid edge; post hoc) | `outputs/p2r/posthoc/{bound.csv,blur_ab.csv,meta.json}` (counts in `meta.json` `n16_wide`), written by `python scripts/31_p2r_posthoc.py` (about 6 min) from the registered summaries and the Oracle test predictions in `outputs/p2r/train/<regime>/cells/*.npz` |
| Sec. 6.3, Table `tab:t4` (dispersion ratio ξ, coverage, training length; post hoc) | `outputs/t4/{summary.csv,cells.csv,budget_dev.csv,meta.json}` (column `kappa` = ξ), written by `python scripts/30_t4_coverage.py` | | Sec. 6.3, Table `tab:t4` (dispersion ratio ξ, coverage, training length; post hoc) | `outputs/t4/{summary.csv,cells.csv,budget_dev.csv,meta.json}` (column `kappa` = ξ), written by `python scripts/30_t4_coverage.py` |
| Sec. 6.4 (mechanism) | Not run yet: T2, to be declared in `docs/research/t2-mechanism.md` | | Sec. 6.4 (mechanism; exploratory), Sec. 7 (bank-gain paragraphs) | `outputs/t2/summary.md` and the tables beside it; declaration `docs/research/t2-mechanism.md` (hashed before computing), results `docs/research/t2-results.md` |
| Sec. 6.5, Table `tab:t3` (detectability; exploratory) | `outputs/t3/{cells.csv,nstar.csv,power.csv,meta.json}`, written by `python scripts/27_t3_power.py`; declaration and Deviation 1 (σ_ref grid) in `docs/research/applicability-teapot.md` | | Sec. 6.5, Tables `tab:benchdesign`, `tab:benchverdicts` (both readings) | Design: `configs/protocol_bench.yaml` (locked 2026-10-29 14:39:20 UTC, sha256 in `.sha256`, time stamp in `.lock.json`), `docs/research/bench-protocol.md`; verdicts as worded: `outputs/bench/summary/verdict_final.{json,md}` and `s3_h2a_stated.csv` (`scripts/36_bench_verdicts.py`); as run by the locked code: `outputs/bench/summary/{verdict.json,summary.md}` (`scripts/34_run_bench.py summarize`); deviation D-13 in `docs/plan.md` §12 item 28; bitwise reproduction check: `logs/bench_repro_r8.out` |
| Sec. 6.6 (gate results) | App. B sources below | | Sec. 6.5 S1, Fig. `fig:bench_s1` (phase diagram, families, additivity fit β and R²) | `outputs/bench/summary/{s1_cells,s1_h2a,s1_families,s1_additivity}.csv`; figure from `scripts/38_bench_figures.py --only bench_s1` |
| Sec. 6.6 (conditions C1–C4) | `outputs/applicability/{verdict.json,c1_pairs.csv,c2_sigma_post.csv,d2_threshold_cells.csv}`, written by `python scripts/26_applicability.py`; `docs/research/applicability-results.md` | | Sec. 6.5 S2, Table `tab:s2` (ratios, cov90, warp RMSE, degradation, Ctl-GP) | `outputs/bench/summary/{s2_cells,s2_h2a,s2_smc,s2_degradation}.csv`; model-error column from `docs/research/bench-protocol.md` (dev 902–905) |
| Sec. 6.6 (Teapot: 152 wells, time–depth tables, horizon–top reference, σ̂_knot 6.75 ms) | `outputs/teapot/inventory/` (`python -P scripts/28_teapot_inventory.py`), `outputs/teapot/pilot_pa/verdict.json` and `knots_dev.csv` (`python -P scripts/29_teapot_pilot.py`), `docs/research/applicability-results.md`, `docs/plan.md` §12 item 23 | | Sec. 6.5 S3 (as worded vs as run; Ctl-GP 16/30) | `outputs/bench/summary/{s3_h2a_stated,s3_h2a,s3_control,s3_table}.csv` |
| Sec. 6.5 S4 (TCN) | `outputs/bench/summary/{s4_cells,s4_h2a}.csv` |
| Sec. 6.5 S8, Table `tab:s8`, Fig. `fig:bench_s8` (two-mode reversal; flip-band means of PM2/BK2/HM2 against cos and cos²) | `outputs/bench/summary/{s8_cells,s8_transfer}.csv`, `s8_transfer_curves.json`; figure from `scripts/38_bench_figures.py --only bench_s8`; flip-band table (usable frequencies in 1/(2Δ) < f < 3/(2Δ)) printed by `scripts/38_bench_figures.py --flipband` (post hoc, not a verdict) |
| Sec. 6.5 "Equal training budgets (disclosed)" | `outputs/bench/summary/equal_budget.csv` |
| Sec. 8 (availability: 630 tasks, 21 methods, scorer) | `benchmark/README.md`, `benchmark/MANIFEST.json`, `benchmark/reference/{cells.csv,main_table.md}` (`scripts/37_bench_package.py`); package `outputs/bench/package/` (Zenodo payload, not yet deposited) |
| Sec. 8 (availability: derived-data archives, licences, clean-room check) | `repro/README.md`, `repro/MANIFEST.json` (five archives, 11,112 files; `scripts/39_repro_package.py build`), `repro/verify_report.md` (`scripts/39_repro_package.py verify`); archives in `outputs/repro/` (not yet deposited) |
| App. A, Sec. 4 (proof review of 02/11/2026) | `docs/plan.md` §12 item 32; Vietnamese statements synced in `docs/theory.md` |
| Sec. 6.6, Table `tab:t3` (detectability; exploratory) | `outputs/t3/{cells.csv,nstar.csv,power.csv,meta.json}`, written by `python scripts/27_t3_power.py`; declaration and Deviation 1 (σ_ref grid) in `docs/research/applicability-teapot.md`. Crossings 3.6, 3.8 and 4.3 ms (R10, R0, Rm5): σ_ref at which `median_ratio` of the N = 16 rows of `cells.csv` reaches 1, by linear interpolation between grid points (`p_better` = 0.5 gives 3.5, 3.8, 4.2 ms); compared with σ/√2 = 3.0, 4.1, 5.1 ms of Corollary 4 |
| Sec. 6.7 (gate results) | App. B sources below |
| Sec. 6.7 (conditions C1–C4) | `outputs/applicability/{verdict.json,c1_pairs.csv,c2_sigma_post.csv,d2_threshold_cells.csv}`, written by `python scripts/26_applicability.py`; `docs/research/applicability-results.md` |
| Sec. 6.7 (Teapot: 152 wells, time–depth tables, horizon–top reference, σ̂_knot 6.75 ms) | `outputs/teapot/inventory/` (`python -P scripts/28_teapot_inventory.py`), `outputs/teapot/pilot_pa/verdict.json` and `knots_dev.csv` (`python -P scripts/29_teapot_pilot.py`), `docs/research/applicability-results.md`, `docs/plan.md` §12 item 23 |
| Sec. 7 (F3 and Volve paragraphs, σ_a, limitations) | same sources as App. B | | Sec. 7 (F3 and Volve paragraphs, σ_a, limitations) | same sources as App. B |
| Sec. 7 ("Where the posterior-mean advantage stops", "When to use a bank", limitations on Experiment 3) | Sec. 6.5 rows above |
| App. B.1, Table `tab:p1` | `outputs/p1/summary.md` | | App. B.1, Table `tab:p1` | `outputs/p1/summary.md` |
| App. B.1, Table `tab:f3gc` (G-C), macro band RMSE | `outputs/p3/summary/gate_gc.json`, `docs/plan.md` §12 item 16 | | App. B.1, Table `tab:f3gc` (G-C), macro band RMSE | `outputs/p3/summary/gate_gc.json`, `docs/plan.md` §12 item 16 |
| App. B.1, Table `tab:f3gc` coverage, seed-by-seed spread | `outputs/p3/summary/{metrics.csv,selection.csv}` (rows with `seed` = ensemble and per seed) | | App. B.1, Table `tab:f3gc` coverage, seed-by-seed spread | `outputs/p3/summary/{metrics.csv,selection.csv}` (rows with `seed` = ensemble and per seed) |
@@ -51,11 +65,11 @@ with the `.venv`); it reads only the locked summaries listed below.
| App. B.2 (best-shift diagnostic) | `outputs/p4/summary/best_shift_DIAGNOSTIC_ONLY.csv` (never alters a score; search limit `best_shift_max_samples` = 16 in the protocol) | | App. B.2 (best-shift diagnostic) | `outputs/p4/summary/best_shift_DIAGNOSTIC_ONLY.csv` (never alters a score; search limit `best_shift_max_samples` = 16 in the protocol) |
| App. B.2 (posterior width, phase) | `outputs/p4/summary/registration.csv` | | App. B.2 (posterior width, phase) | `outputs/p4/summary/registration.csv` |
| App. B.2 (deviations), Sec. 7 (Volve paragraphs) | `configs/protocol_volve.yaml` (`deviations`), `configs/protocol_volve.lock.json`, `docs/plan.md` §12 items 19–21 | | App. B.2 (deviations), Sec. 7 (Volve paragraphs) | `configs/protocol_volve.yaml` (`deviations`), `configs/protocol_volve.lock.json`, `docs/plan.md` §12 items 19–21 |
| Pass rules, thresholds | `configs/protocol_p2.yaml`, `configs/protocol_p2r.yaml`, `configs/protocol_f3.yaml` (locked; tag `protocol-f3`), `configs/protocol_volve.yaml` (locked 2026-10-29 01:17:42 UTC; committed on 2026-10-29 after the run, tag `protocol-volve`) | | Pass rules, thresholds | `configs/protocol_p2.yaml`, `configs/protocol_p2r.yaml`, `configs/protocol_f3.yaml` (locked; tag `protocol-f3`), `configs/protocol_volve.yaml` (locked 2026-10-29 01:17:42 UTC; committed on 2026-10-29 after the run, tag `protocol-volve`), `configs/protocol_bench.yaml` (locked 2026-10-29 14:39:20 UTC; committed in 381b5ff while the main runs were in progress; no tag) |
Do not copy numbers from `code_thesis/` (thesis archive) into the paper. P4x was dropped on 29/10/2026 (Pivot 1, `docs/plan.md` §12 item 22): nothing from `outputs/p4x/` or `docs/research/p4-exploratory.md` enters the paper. Do not copy numbers from `code_thesis/` (thesis archive) into the paper. P4x was dropped on 29/10/2026 (Pivot 1, `docs/plan.md` §12 item 22): nothing from `outputs/p4x/` or `docs/research/p4-exploratory.md` enters the paper.
Wording must respect `docs/plan.md` §10 (forbidden claims). Wording must respect `docs/plan.md` §10 (forbidden claims).
Length: Computers & Geosciences limits a Research Article to about 5,500 words excluding abstract, keywords, highlights, Length: Computers & Geosciences limits a Research Article to about 5,500 words excluding abstract, keywords, highlights,
references and captions (secondary source; the official Guide for Authors page could not be fetched on 2026-10-29). references and captions (secondary source; the official Guide for Authors page could not be fetched on 2026-10-29).
The main text (Secs. 1–8) is about 14,950 words (crude count after the 30/10 writing pass), and exceeds that limit. The length pass was dropped by the user on 2026-10-29 (`docs/plan.md` §12 item 25). The main text (Secs. 1–8) is about 18,100 words (crude count after the 02/11 writing pass, which added about 3,100 words for Experiment 3, the mechanism study and the discussion; the proof review of the same day added about 350 more and the full-text pass of Sec. 2 about 130, estimated; 68 pages), and exceeds that limit. The length pass was dropped by the user on 2026-10-29 (`docs/plan.md` §12 item 25).

BIN
paper/figures/bench_s1.pdf Normal file

Binary file not shown.

BIN
paper/figures/bench_s8.pdf Normal file

Binary file not shown.

View File

@@ -56,8 +56,7 @@
\theoremstyle{remark} \theoremstyle{remark}
\newtheorem{remark}{Remark} \newtheorem{remark}{Remark}
\title{Label registration error in sparse-well seismic property learning: theory, a registration-aware benchmark, and the limits of field validation\\[4pt] \title{Label registration error in sparse-well seismic property learning: theory, a registration-aware benchmark, and the limits of field validation}
\normalsize\todo{If S2 of \texttt{protocol\_bench} is not locked and run before submission, replace ``a registration-aware benchmark'' with ``a controlled synthetic study'' in the title, abstract and text.}}
\author{\todo{author list, affiliations, ORCID, corresponding author}} \author{\todo{author list, affiliations, ORCID, corresponding author}}
\date{Draft, \today} \date{Draft, \today}

View File

@@ -62,7 +62,7 @@
pages = {M185--M196}, pages = {M185--M196},
doi = {10.1190/geo2023-0737.1}, doi = {10.1190/geo2023-0737.1},
url = {https://doi.org/10.1190/geo2023-0737.1}, url = {https://doi.org/10.1190/geo2023-0737.1},
annote = {P05; survey evidence level A; accessed 2026-10-23; full text not obtainable (confirmed 2026-10-28): cite as abstract-only} annote = {P05; survey evidence level A; accessed 2026-10-23; full text read 2026-11-02 (refs/li2024bpinn.pdf). BNN-VI and BPINN-VI with uncertainty over network weights; synthetic test with 12/3 pseudowells extracted from the true sections; North Sea field case with the forward model calibrated by a deterministic well-to-seismic tie. No tie uncertainty}
} }
@article{ntibahanana2024ensemble, @article{ntibahanana2024ensemble,
@@ -191,7 +191,7 @@
% --- Added 2026-10-26 from docs/plan.md section 11. Full text is in refs/ for every entry below. % --- Added 2026-10-26 from docs/plan.md section 11. Full text is in refs/ for every entry below.
% DOI, volume and pages from Crossref (journal articles) or the arXiv/PMLR record (ML papers). % DOI, volume and pages from Crossref (journal articles) or the arXiv/PMLR record (ML papers).
% Not included (no full text, or no verifiable record): White & Simm 2003, % Not included (no full text, or no verifiable record): White & Simm 2003,
% Herrera & van der Baan 2014 (journal version), Munoz & Hale 2015, RING 2025, EAGE 2023 (skipped: not found or not obtainable). % Herrera & van der Baan 2014 (journal version; added 2026-11-02 as abstract-only, see below), Munoz & Hale 2015, RING 2025, EAGE 2023 (skipped: not found or not obtainable).
@article{buland2003bayesianwavelet, @article{buland2003bayesianwavelet,
author = {Buland, Arild and Omre, Henning}, author = {Buland, Arild and Omre, Henning},
@@ -264,7 +264,7 @@
archivePrefix = {arXiv}, archivePrefix = {arXiv},
primaryClass = {physics.geo-ph}, primaryClass = {physics.geo-ph},
url = {https://arxiv.org/abs/1209.0201}, url = {https://arxiv.org/abs/1209.0201},
annote = {Early preprint of the DTW well-tie method; the Geophysics 2014 paper (79(3), V47--V54, 10.1190/GEO2013-0248.1) was not available, cite the version actually read} annote = {Early preprint of the DTW well-tie method, read in full (refs/). The Geophysics 2014 version is cited alongside as abstract-only (herrera2014semiautomatic); statements about the constraint and the advice against blind use rest on that abstract}
} }
@inproceedings{cuturi2017softdtw, @inproceedings{cuturi2017softdtw,
@@ -426,7 +426,7 @@
pages = {16--20}, pages = {16--20},
doi = {10.1190/image2025-4304877.1}, doi = {10.1190/image2025-4304877.1},
url = {https://doi.org/10.1190/image2025-4304877.1}, url = {https://doi.org/10.1190/image2025-4304877.1},
annote = {Abstract only (OpenAlex). Joint Bayesian inversion of time-depth transform parameters and wavelet(s) by PT-MCMC with uncertainty estimates; pre-stack wavelets for AVO/AVA. No learned property prediction mentioned} annote = {Full text read 2026-11-02 (refs/lim2025awsm.pdf). PT-MCMC over stretch/shift/pinch-point parameters of a TD model anchored to a horizon and a well top, jointly with wavelets; 44 Midland Basin wells in about 50 min; median- and minimum-misfit models kept; angle-consistent wavelets for AVO/AVA. The TD posterior is reported but not used by any later step; no learned property prediction}
} }
@inproceedings{lim2025bootnet, @inproceedings{lim2025bootnet,
@@ -438,7 +438,7 @@
pages = {56--60}, pages = {56--60},
doi = {10.1190/image2025-4304887.1}, doi = {10.1190/image2025-4304887.1},
url = {https://doi.org/10.1190/image2025-4304887.1}, url = {https://doi.org/10.1190/image2025-4304887.1},
annote = {Abstract only (OpenAlex). Bootstrapped ensemble of DNNs trained on Zoeppritz synthetics; impedance, velocity ratio and density with an uncertainty map; Midland Basin} annote = {Full text read 2026-11-02 (refs/lim2025bootnet.pdf). Bootstrapped ensemble (B = 100) of DNNs trained on rock-physics logs with Zoeppritz synthetics; impedance, velocity ratio and density with an uncertainty map; Midland Basin. Training pairs are synthetic; no well tie or tie uncertainty}
} }
@inproceedings{quesada2024faultlabels, @inproceedings{quesada2024faultlabels,
@@ -448,7 +448,7 @@
publisher = {Society of Exploration Geophysicists}, publisher = {Society of Exploration Geophysicists},
year = {2024}, year = {2024},
url = {https://alregib.ece.gatech.edu/image-2024-papers/jorge-image-2024/}, url = {https://alregib.ece.gatech.edu/image-2024-papers/jorge-image-2024/},
annote = {Abstract only (authors' lab page). DOI and pages not found in Crossref/OpenAlex on 2026-10-28: add before submission. 400 F3 images, 38 annotators (29 novices, 8 practitioners, 1 expert), three confidence levels} annote = {Abstract only (authors' lab page). DOI and pages not found in Crossref/OpenAlex on 2026-10-28, nor on 2026-11-02 (Crossref title/author queries; none of the 555 OpenAlex records with prefix 10.1190/image2024 matches; the lab page gives no DOI): retry on the submission day, otherwise cite with the lab-page URL. 400 F3 images, 38 annotators (29 novices, 8 practitioners, 1 expert), three confidence levels}
} }
@inproceedings{huff2024anglestack, @inproceedings{huff2024anglestack,
@@ -484,7 +484,7 @@
pages = {1--5}, pages = {1--5},
doi = {10.3997/2214-4609.202410525}, doi = {10.3997/2214-4609.202410525},
url = {https://doi.org/10.3997/2214-4609.202410525}, url = {https://doi.org/10.3997/2214-4609.202410525},
annote = {Abstract only (OpenAlex). Variational inference with a multiscale (wavelet-based) normalizing flow for the post-stack inversion posterior} annote = {Full text read 2026-11-02 (refs/rizzuti2024waveletflows.pdf). Variational inference with a multiscale (wavelet-based) normalizing flow for the post-stack inversion posterior; Volve 2D section; no training labels, no tie uncertainty}
} }
@inproceedings{cordoba2025porosity, @inproceedings{cordoba2025porosity,
@@ -520,7 +520,7 @@
pages = {1--5}, pages = {1--5},
doi = {10.3997/2214-4609.202510205}, doi = {10.3997/2214-4609.202510205},
url = {https://doi.org/10.3997/2214-4609.202510205}, url = {https://doi.org/10.3997/2214-4609.202510205},
annote = {Abstract only (OpenAlex). Variational Bayesian UHR post-stack inversion with normalizing flows; acoustic-impedance credible intervals; offshore wind site} annote = {Full text read 2026-11-02 (refs/rizzuti2025uhr.pdf). Variational Bayesian UHR post-stack inversion with normalizing flows; acoustic-impedance credible intervals; offshore wind site. Known wavelet estimated at the trace nearest a projected CPT site; integrating CPT logs and wavelet effects into the UQ framework named as future work}
} }
@article{guillon2020gtmetrics, @article{guillon2020gtmetrics,
@@ -533,7 +533,7 @@
pages = {734--741}, pages = {734--741},
doi = {10.1190/tle39100734.1}, doi = {10.1190/tle39100734.1},
url = {https://doi.org/10.1190/tle39100734.1}, url = {https://doi.org/10.1190/tle39100734.1},
annote = {Abstract only (OpenAlex). Precision/recall/IoU with a tolerance distance between prediction and ground truth for thin faults and horizons} annote = {Full text read 2026-11-02 (refs/guillon2020gtmetrics.pdf). Precision/recall/IoU with a Gaussian tolerance function of the distance between prediction and ground truth for thin faults and horizons; motivated by interpreter pick differences of a few pixels. Tolerance in evaluation only; tolerance-aware loss named as future work}
} }
@article{berkson1950two, @article{berkson1950two,
@@ -627,3 +627,65 @@
url = {https://doi.org/10.1109/TIT.1962.1057717}, url = {https://doi.org/10.1109/TIT.1962.1057717},
annote = {Metadata verified via Crossref 2026-10-29 (Crossref lists the successor name IEEE Transactions on Information Theory). Abstract and full text not obtained. Cited only for the general statement that the spectral effect of random timing errors has been studied for sampling jitter; Schwarzmann and Kaeser (arXiv:2509.04199, Sec. II) cite it for "spectral distortion under random timing perturbations".} annote = {Metadata verified via Crossref 2026-10-29 (Crossref lists the successor name IEEE Transactions on Information Theory). Abstract and full text not obtained. Cited only for the general statement that the spectral effect of random timing errors has been studied for sampling jitter; Schwarzmann and Kaeser (arXiv:2509.04199, Sec. II) cite it for "spectral distortion under random timing perturbations".}
} }
% ---- Added 2026-11-02: preliminary novelty scan (Crossref, OpenAlex 2025--2026, web search; plan section 12 item 31).
% Metadata from Crossref on 2026-11-02; abstracts read via OpenAlex. No full text for any of these: cite as abstract-only.
@article{herrera2014semiautomatic,
author = {Herrera, Roberto H. and van der Baan, Mirko},
title = {{A semiautomatic method to tie well logs to seismic data}},
journal = {Geophysics},
year = {2014},
volume = {79},
number = {3},
pages = {V47--V54},
doi = {10.1190/geo2013-0248.1},
url = {https://doi.org/10.1190/geo2013-0248.1},
annote = {Abstract only (OpenAlex, 2026-11-02; not open access). Published version of herrera2012automatedtie. Constrained DTW replaces the manual stretch-and-squeeze step; bounds set by the interpreter; authors advise against unsupervised use (a guide, not a blind method). No tie uncertainty mentioned}
}
@article{dacostasilva2026autotie,
author = {da Costa Silva, Rafael and de Souza Ara{\'u}jo, Marcelus Glaucus and Rozendo, Luiz Antonio and Furtado Silva, Diego},
title = {{Autotie: A partial automation of the seismic-to-well tie with matching region estimation}},
journal = {Geophysics},
year = {2026},
volume = {91},
number = {5},
pages = {IM87--IM100},
doi = {10.1190/geo-2024-0011},
url = {https://doi.org/10.1190/geo-2024-0011},
annote = {Abstract only (OpenAlex, 2026-11-02). Time-weighted DTW for the matching position, global Bayesian optimizer for the tie parameters, segment-wise constrained DTW for velocity perturbation and wavelet phase within a tolerance; correlation improved at all six wells (four above 70%). Output is a single tie; no tie uncertainty and no learned property prediction mentioned}
}
@article{castagna2026quality,
author = {Castagna, John and Kronberg, V{\`i} and Gil, Gabriel},
title = {{How should the ``quality'' of seismic well ties and predictions of rock properties using machine learning be assessed?}},
journal = {The Leading Edge},
year = {2026},
volume = {45},
number = {5},
pages = {378--390},
doi = {10.1190/tle-2025-1058},
url = {https://doi.org/10.1190/tle-2025-1058},
annote = {Full text read 2026-11-02 (refs/castagna2026quality.pdf, CC BY). The correlation coefficient is inadequate for comparing seismic or predictions with presumed truth (synthetics or well logs); information-theoretic measures (cross entropy, variation of information, channel capacity) proposed, also as ML losses; DaQing and Permian Basin examples (porosity from five wells by sparse nonlinear regression). Discussion: time-depth functions are never exact, time shifts degrade mainly higher frequencies; the distribution-based measures are insensitive to small shifts. Timing error is not modelled and not used in training; the tie of the five Permian wells is not described}
}
% ---- Datasets (added 2026-11-02; metadata read from the providers' pages on 2026-11-02) ----
@misc{dgb2023f3demo,
author = {{dGB Earth Sciences}},
title = {{F3 Demo 2023}: {OpendTect} project of the {F3} block, {Dutch} sector of the {North Sea}},
howpublished = {TerraNubis data portal, dataset. Original seismic: NAM; original source: NLOG},
year = {2023},
url = {https://terranubis.com/datainfo/F3-Demo-2023},
note = {Licence: Creative Commons BY-SA 3.0. Accessed 26 October 2026},
annote = {Page title "Project F3 Demo 2023"; no release date or DOI on the page ("Value added Products: 2023"; acquisition and processing 1987). Licence link points to creativecommons.org/licenses/by-sa/3.0. Requested acknowledgement: "We thank dGB Earth Sciences for making the data available as an OpendTect project via their TerraNubis portal (terranubis.com)." Downloaded 2026-10-26 (data_manifest/f3_demo_2023.json).}
}
@misc{equinor2018volve,
author = {{Equinor}},
title = {{Volve} field data set},
howpublished = {Equinor ASA, dataset. Data owners: Equinor, ExxonMobil, Bayerngas and the Norwegian Petroleum Directorate},
year = {2018},
url = {https://www.equinor.com/energy/volve-data-sharing},
note = {Released 14 June 2018. Accessed 26 October 2026},
annote = {The web page grants use under the "Equinor Open Data Licence"; the license.txt files of the release name "Creative Commons Attribution 4.0 International license (CC BY NC SA)" with a link to CC BY-NC-SA 4.0, forbid resale and require attribution of the data owners (Equinor, ExxonMobil, Bayerngas, NPD). Downloaded 2026-10-26 (data_manifest/volve.json).}
}

View File

@@ -1,5 +1,5 @@
\begin{abstract} \begin{abstract}
Seismic reservoir-property predictors are trained on well logs that a well tie places in two-way time, and the tie is uncertain. We analyse its error as an error in the time index of the label. Under an independence assumption, misregistered labels convolve the optimal predictor with the error distribution and blur the seismic band; a controlled experiment matched the predicted transfer to within 1\% for errors of 4--16\,ms. Without time anchors, absolute timing is not identified. A tie computed as a posterior mean has the opposite, Berkson, error structure and sharpens the predictor instead. A calibrated bank of posterior labels attains the oracle's population optimum, but its population gain over a point label is of fourth order in the tie error. On a registration-aware synthetic benchmark calibrated to F3, we compared point ties, posterior-mean labels and a tempered likelihood over a posterior bank under pre-registered rules. The first comparison failed, and the second was designed after that failure. There, posterior-mean labels had 8--22\% lower seismic-band RMSE than the best point tie, most of it already without drift, but failed when the anchor uncertainty was set at half or twice its true value. With 16 training wells, the bank gained further in all eight cells with a wide posterior. This gain exceeded the registered population bound for classical tie error in seven cells, but a post hoc bound for Berkson error in only three. Detecting such gains at blind wells requires an accurate reference: with an exact reference, 5--18 wells gave a power of 0.8 in most cells; with reference errors of 3\,ms or more, 40 wells did not. The F3 and Volve field tests (four and six wells) failed, and neither could have detected such gains. Teapot Dome has independent time--depth references at no more than two of its 152 wells. We make no field or calibration claim. Seismic reservoir-property predictors are trained on well logs that a well tie places in two-way time, and the tie is uncertain. We analyse its error as an error in the time index of the label. Under an independence assumption, misregistered labels convolve the optimal predictor with the error distribution and blur the seismic band; a controlled experiment matched the predicted transfer to within 1\% for errors of 4--16\,ms. Without time anchors, absolute timing is not identified. In a linear-Gaussian idealization, a tie computed as a posterior mean has the opposite, Berkson, error structure and sharpens the predictor instead. A calibrated bank of posterior labels attains the oracle's population optimum, but its population gain over a point label is of fourth order in the tie error. On a registration-aware synthetic benchmark calibrated to F3, we compared point ties, posterior-mean labels and a tempered likelihood over a posterior bank under pre-registered rules. The first comparison failed, and the second was designed after that failure. There, posterior-mean labels had 8--22\% lower seismic-band RMSE than the best point tie, most of it already without drift, but failed when the anchor uncertainty was set at half or twice its true value. With 16 training wells, the bank gained further in all eight cells with a wide posterior. This gain exceeded the registered population bound for classical tie error in seven cells, but in only three the post hoc bound for Berkson error, the structure that an exploratory test found at F3-like drift. A third pre-registered experiment, designed after the field tests and run on the same test realizations, passed 9 of its 11 verdicts. The posterior-mean advantage extended to stronger drift, a second backbone and a misspecified warp prior, but not to a frequency-dependent wavelet phase, which made the tie posterior overconfident, nor, by the registered margin, to unit-dependent rock physics. With a two-mode label error, midpoint labels reversed the sign of the learned seismic band as predicted, and a two-member bank containing the true warp removed the reversal. Detecting such gains at blind wells requires an accurate reference: with an exact reference, 5--18 wells gave a power of 0.8 in most cells; with reference errors of 3\,ms or more, 40 wells did not. The F3 and Volve field tests (four and six wells) failed, and neither could have detected such gains. Teapot Dome has independent time--depth references at no more than two of its 152 wells. We make no field or calibration claim.
\end{abstract} \end{abstract}
\noindent\textbf{Keywords:} well tie; registration error; errors-in-variables; seismic porosity prediction; synthetic benchmark; blind-well validation; statistical power \noindent\textbf{Keywords:} well tie; registration error; errors-in-variables; seismic porosity prediction; synthetic benchmark; blind-well validation; statistical power

View File

@@ -10,11 +10,11 @@ The size of the timing error is easy to underestimate. At the four public wells
This is a label error of a particular kind. The label values are measured, but they are placed at the wrong times. Work on noisy labels and on errors in variables mostly concerns errors in the values (Section~\ref{sec:related}). A registration error acts on the time index instead: it is correlated along the well, its effect depends on frequency, and it affects the reference against which blind wells are scored as well as the training labels. We ask what such an error does to a learned predictor, whether training on a tie posterior rather than a point tie removes its effect, and whether a field test can detect the difference. We make four contributions. This is a label error of a particular kind. The label values are measured, but they are placed at the wrong times. Work on noisy labels and on errors in variables mostly concerns errors in the values (Section~\ref{sec:related}). A registration error acts on the time index instead: it is correlated along the well, its effect depends on frequency, and it affects the reference against which blind wells are scored as well as the training labels. We ask what such an error does to a learned predictor, whether training on a tie posterior rather than a point tie removes its effect, and whether a field test can detect the difference. We make four contributions.
\begin{enumerate} \begin{enumerate}
\item[C1] \textbf{Theory.} Under an independence assumption, the MSE-optimal predictor trained on misregistered labels is the correctly registered predictor convolved with the distribution of the timing error, so the seismic band is attenuated by the characteristic function of the error (Proposition~\ref{prop:blur}). A controlled experiment matches this transfer to within 1\% for errors of 4--16\,ms, in the band where the predictor has coherent power. Without time anchors, a shared network and its label alignment can drift together without changing the loss (Proposition~\ref{prop:ident}), so losses that learn the alignment from the network's own predictions, such as soft-DTW \citep{cuturi2017softdtw} and DILATE \citep{leguen2019dilate}, cannot fix absolute timing. The error of an estimated tie can have the classical structure, which blurs the learned predictor, or the Berkson structure, which sharpens it (Proposition~\ref{prop:tie}). A calibrated bank of posterior labels has the population minimizer of training on the true labels, but its population gain over a point label is of fourth order in the tie error (Proposition~\ref{prop:bank}). We also relate the coverage of predictive intervals to the error structure (Proposition~\ref{prop:coverage}) and give the bias of scoring against a misregistered reference (Proposition~\ref{prop:reference}). \item[C1] \textbf{Theory.} Under an independence assumption, the MSE-optimal predictor trained on misregistered labels is the correctly registered predictor convolved with the distribution of the timing error, so the seismic band is attenuated by the characteristic function of the error (Proposition~\ref{prop:blur}). A controlled experiment matches this transfer to within 1\% for errors of 4--16\,ms, in the band where the predictor has coherent power. Without time anchors, a shared network and its label alignment can drift together without changing the loss (Proposition~\ref{prop:ident}), so losses that learn the alignment from the network's own predictions, such as soft-DTW \citep{cuturi2017softdtw} and DILATE \citep{leguen2019dilate}, cannot fix absolute timing. The error of an estimated tie can have the classical structure, which blurs the learned predictor, or the Berkson structure, which sharpens it (Proposition~\ref{prop:tie}). A calibrated bank of posterior labels has the population minimizer of training on the true labels, but its population gain over a point label is of fourth order in the tie error (Proposition~\ref{prop:bank}). We also relate the coverage of predictive intervals to the error structure (Proposition~\ref{prop:coverage}) and give the bias of scoring against a misregistered reference (Proposition~\ref{prop:reference}).
\item[C2] \textbf{A registration-aware benchmark.} We build synthetic data with known true warps from F3 geometry, rock physics and time--depth statistics. We vary drift, seismic signal-to-noise ratio and anchor density, and evaluate under locked, pre-registered pass rules. We report both comparisons that we registered: the first failed, and the second, designed after that failure, passed, with an explicit dependence on correctly specified anchor uncertainty. \todo{S1, S2, S3, S4 and S8 of \texttt{protocol\_bench}: grid fill, misspecification axes, B4 under the SMC posterior, second backbone, controlled cycle skipping.} \item[C2] \textbf{A registration-aware benchmark.} We build synthetic data with known true warps from F3 geometry, rock physics and time--depth statistics. We vary drift, seismic signal-to-noise ratio and anchor density, and evaluate under locked, pre-registered pass rules. We report both comparisons that we registered: the first failed, and the second, designed after that failure, passed, with an explicit dependence on correctly specified anchor uncertainty. A third experiment, designed after the field tests, fills the plane of drift and well count, misspecifies the rock physics, the wavelet and the drift, adds the anchor-free losses and a second backbone, and imposes a two-mode label error of known structure. We release it as a task package with hidden truth and a scorer that applies the locked rules.
\item[C3] \textbf{A family of baselines.} Registration-marginalized learning (RML$_\lambda$), a tempered log-likelihood over a bank of labels, contains point-tie training, hard-min and soft-min shift losses and soft-DTW as special cases (Lemmas~\ref{lem:s1}--\ref{lem:sdtw}). We use this family to define the methods compared on the benchmark, not as a proposed method that wins. \item[C3] \textbf{A family of baselines.} Registration-marginalized learning (RML$_\lambda$), a tempered log-likelihood over a bank of labels, contains point-tie training, hard-min and soft-min shift losses and soft-DTW as special cases (Lemmas~\ref{lem:s1}--\ref{lem:sdtw}). We use this family to define the methods compared on the benchmark, not as a proposed method that wins.
\item[C4] \textbf{Detectability and the scope of field tests.} We derive how accurately the reference at blind wells must be tied, and how many blind wells are needed, for a comparison of tie methods to detect the effects of C1 (Corollary~\ref{cor:tolerance}, Section~\ref{sec:exp:detect}). We audit the public F3 well data: the porosity labels at three of the four wells are a linear function of the sonic log, and the time--depth markers are horizon-tie picks, not check shots. Pre-registered field tests on F3 and Volve failed, and an inventory of Teapot Dome found an independent time--depth reference at no more than two of its wells. These cases bound the scope of the paper. \item[C4] \textbf{Detectability and the scope of field tests.} We derive how accurately the reference at blind wells must be tied, and how many blind wells are needed, for a comparison of tie methods to detect the effects of C1 (Corollary~\ref{cor:tolerance}, Section~\ref{sec:exp:detect}). We audit the public F3 well data: the porosity labels at three of the four wells are a linear function of the sonic log, and the time--depth markers are horizon-tie picks, not check shots. Pre-registered field tests on F3 and Volve failed, and an inventory of Teapot Dome found an independent time--depth reference at no more than two of its wells. These cases bound the scope of the paper.
\end{enumerate} \end{enumerate}
On the benchmark, labels at the posterior-mean warp of a sequential Monte Carlo tie beat the best point tie by 8--22\% in seismic-band RMSE at F3-like drift in all three full-anchor regimes. Most of this advantage was already present without drift, so part of it comes from the seismic-conditioned tie itself rather than from correcting drift. With the anchor uncertainty set at half or twice its true value, this advantage no longer passed the registered rule. A bank of posterior samples gained further when the posterior was wide, in all eight such cells with 16 training wells. In seven of these eight cells this gain exceeded the population bound that we registered, which assumes classical tie error, but in only three did it exceed the bound for the Berkson error of a posterior-mean tie, which we computed post hoc. With an exact reference, a sign test at blind wells needed 5--18 wells to detect these gains in most cells, and with reference errors of 3\,ms or more, 40 wells did not suffice. Neither public field dataset that we tested meets these conditions. On the benchmark, labels at the posterior-mean warp of a sequential Monte Carlo tie beat the best point tie by 8--22\% in seismic-band RMSE at F3-like drift in all three full-anchor regimes. Most of this advantage was already present without drift, so part of it comes from the seismic-conditioned tie itself rather than from correcting drift. With the anchor uncertainty set at half or twice its true value, this advantage no longer passed the registered rule. A bank of posterior samples gained further when the posterior was wide, in all eight such cells with 16 training wells. In seven of these eight cells this gain exceeded the population bound that we registered, which assumes classical tie error, but in only three did it exceed the bound for the Berkson error of a posterior-mean tie, which we computed post hoc; an exploratory test found the Berkson structure at F3-like drift. In the third experiment, 9 of 11 pre-registered verdicts passed. The posterior-mean advantage held at stronger drift, with a second backbone and under a misspecified warp prior, but failed under a frequency-dependent wavelet phase and, by the registered margin, under unit-dependent rock physics. The bank gain grew with the number of wells, and a two-mode label error reversed the sign of the learned seismic band as predicted, a reversal that a bank containing the true warp removed. With an exact reference, a sign test at blind wells needed 5--18 wells to detect these gains in most cells, and with reference errors of 3\,ms or more, 40 wells did not suffice. Neither public field dataset that we tested meets these conditions.
Section~\ref{sec:related} positions the work. Section~\ref{sec:data} describes the data and the audit, Section~\ref{sec:theory} the theory, and Section~\ref{sec:method} the tie posterior and the methods. Section~\ref{sec:experiments} reports the benchmark, the detectability analysis and the field cases. Section~\ref{sec:discussion} discusses what the results imply for field studies, and the limitations. Proofs are in Appendix~\ref{app:proofs}, and the field tests in Appendix~\ref{app:field}. Section~\ref{sec:related} positions the work. Section~\ref{sec:data} describes the data and the audit, Section~\ref{sec:theory} the theory, and Section~\ref{sec:method} the tie posterior and the methods. Section~\ref{sec:experiments} reports the benchmark, the detectability analysis and the field cases. Section~\ref{sec:discussion} discusses what the results imply for field studies, and the limitations. Proofs are in Appendix~\ref{app:proofs}, and the field tests in Appendix~\ref{app:field}.

View File

@@ -4,10 +4,10 @@
Three bodies of work meet in this problem and have so far been developed separately: well ties with uncertainty, learned property prediction from few wells, and losses that tolerate temporal misalignment. Two others study uncertain labels, in statistics and machine learning in general and in learned seismic interpretation. We review each in turn and then state what is new. Three bodies of work meet in this problem and have so far been developed separately: well ties with uncertainty, learned property prediction from few wells, and losses that tolerate temporal misalignment. Two others study uncertain labels, in statistics and machine learning in general and in learned seismic interpretation. We review each in turn and then state what is new.
\paragraph{Well ties and their uncertainty.} \paragraph{Well ties and their uncertainty.}
Posteriors over the well tie exist, but in every method we found the tie is the end product. \citet{buland2003bayesianwavelet} model the mistie between seismic time and log time as latent marker shifts with a triangular prior. They estimate these shifts jointly with the wavelet by MCMC and report their posterior. \citet{gunning2006waveletextractor} estimate the wavelet jointly with check-shot and marker times (Gaussian priors, monotonicity enforced), a registration shift and a lateral positioning error per well. They obtain uncertainty from a Laplace approximation and choose the wavelet length by marginal likelihood. \citet{lim2025awsm} infer time--depth transform parameters and wavelets jointly with parallel-tempering MCMC and report uncertainty estimates for a Midland Basin case study. Neither prior over time shifts nor a posterior over the time--depth relation is therefore new. In these works, however, the posterior is not used further. \citet{lim2025awsm} pass the estimated wavelets on to AVO/AVA inversion; their abstract does not describe passing the time--depth uncertainty on to a later step. \citet{wu2017multiwelltie} tie several wells at once with smooth depth-variable shifts and give no tie uncertainty. \citet{herrera2012automatedtie} use dynamic time warping for the tie. Among learning-based methods, \citet{tschannen2022partialtie} estimate the wavelet with a variational network: their uncertainty is mainly in wavelet phase, and the bulk shift is found by Bayesian optimization within user-set bounds. \citet{di2023welltie} and \citet{li2025cascadedtie} automate the tie with self-supervised learning and cascaded matching. All these methods output a tie, sometimes with wavelet or shift uncertainty, and stop there. Posteriors over the well tie exist, but in every method we found the tie is the end product. \citet{buland2003bayesianwavelet} model the mistie between seismic time and log time as latent marker shifts with a triangular prior. They estimate these shifts jointly with the wavelet by MCMC and report their posterior. \citet{gunning2006waveletextractor} estimate the wavelet jointly with check-shot and marker times (Gaussian priors, monotonicity enforced), a registration shift and a lateral positioning error per well. They obtain uncertainty from a Laplace approximation and choose the wavelet length by marginal likelihood. \citet{lim2025awsm} start from a time--depth model anchored to an interpreted horizon and a well top, sample its stretch, shift and pinch-point parameters jointly with the wavelet by parallel-tempering MCMC, and report the resulting time--depth uncertainty for 44 wells in the Midland Basin. Neither prior over time shifts nor a posterior over the time--depth relation is therefore new. In these works, however, the posterior is not used further. \citet{lim2025awsm} keep two representative samples, the median-misfit and the minimum-misfit model, and estimate angle-consistent wavelets for AVO/AVA inversion; no later step in their workflow uses the time--depth posterior. \citet{wu2017multiwelltie} tie several wells at once with smooth depth-variable shifts and give no tie uncertainty. \citet{herrera2012automatedtie} use dynamic time warping for the tie. In the published version \citep{herrera2014semiautomatic}, the warping replaces the manual stretch-and-squeeze step within bounds set by the interpreter, and is meant as a guide rather than a blind method. \citet{dacostasilva2026autotie} combine time-weighted dynamic time warping, Bayesian optimization of the tie parameters and segment-wise alignment; their abstract reports higher correlations at six wells and no tie uncertainty. Among learning-based methods, \citet{tschannen2022partialtie} estimate the wavelet with a variational network: their uncertainty is mainly in wavelet phase, and the bulk shift is found by Bayesian optimization within user-set bounds. \citet{di2023welltie} and \citet{li2025cascadedtie} automate the tie with self-supervised learning and cascaded matching. All these methods output a tie, sometimes with wavelet or shift uncertainty, and stop there.
\paragraph{Learning reservoir properties from seismic with few wells.} \paragraph{Learning reservoir properties from seismic with few wells.}
Recent studies predict porosity or impedance with convolutional, recurrent or transformer networks, sometimes with physics constraints or uncertainty estimates \citep{alfarraj2019semisupervised,vashisth2022rwpinn,liu2023lowfrequency,xu2024sts,chen2024multidimensional,li2024bpinn,ntibahanana2024ensemble,corrales2024seis2rock,dou2024seismae,tao2025structural,prabowo2025f3,cordoba2025porosity,rezaei2026krigingrf,sukar2026uncertainty}. In the studies we read in full, the labels are placed on the seismic time axis by a tie that is taken as given. \citet{xu2024sts} say so explicitly, and their augmentation shifts windows laterally, not in time. \citet{ali2025syntheticpseudowells} name the seismic-to-well tie discrepancy as a challenge and avoid it by training on synthetic pseudo-wells. Where uncertainty is estimated, it is the uncertainty of the network or of the data noise. It does not include the uncertainty of the label timing. \citet{cordoba2025porosity} report noise-sensitivity tests, but their abstract does not mention the tie or misregistered labels. Bayesian and variational inversions give posteriors or credible intervals for porosity or impedance \citep{thiebaud2024lfc,rizzuti2024waveletflows,rizzuti2025uhr}, and a bootstrapped network ensemble gives a spread of elastic-property predictions \citep{lim2025bootnet}. None of these abstracts names the well tie as a source of uncertainty. Recent studies predict porosity or impedance with convolutional, recurrent or transformer networks, sometimes with physics constraints or uncertainty estimates \citep{alfarraj2019semisupervised,vashisth2022rwpinn,liu2023lowfrequency,xu2024sts,chen2024multidimensional,li2024bpinn,ntibahanana2024ensemble,corrales2024seis2rock,dou2024seismae,tao2025structural,prabowo2025f3,cordoba2025porosity,rezaei2026krigingrf,sukar2026uncertainty}. In the studies we read in full, the labels are placed on the seismic time axis by a tie that is taken as given, or, in \citet{sukar2026uncertainty}, are simulated property changes paired with synthetic 4D attribute maps from a history-matched simulation model, so that no well tie places them. \citet{xu2024sts} say so explicitly, and their augmentation shifts windows laterally, not in time. \citet{li2024bpinn} calibrate the forward model of their Bayesian physics-informed network at the wells with a well-to-seismic tie that is then fixed; their posterior is over network weights. \citet{ali2025syntheticpseudowells} name the seismic-to-well tie discrepancy as a challenge and avoid it by training on synthetic pseudo-wells. Where uncertainty is estimated, it is the uncertainty of the network or of the data noise. It does not include the uncertainty of the label timing. \citet{cordoba2025porosity} report noise-sensitivity tests, but their abstract does not mention the tie or misregistered labels. Bayesian and variational inversions give posteriors or credible intervals for porosity or impedance \citep{thiebaud2024lfc,rizzuti2024waveletflows,rizzuti2025uhr}, and a bootstrapped ensemble of networks trained on rock-physics synthetics gives a spread of elastic-property predictions \citep{lim2025bootnet}. None of these works treats the well tie as a source of uncertainty (for \citet{thiebaud2024lfc} we read the abstract only). \citet{rizzuti2025uhr} treat the wavelet as known, estimated at the trace nearest a projected cone-penetration-test site, and list bringing these logs and wavelet effects into the uncertainty framework as future work. How tie and prediction quality should be scored is itself debated: \citet{castagna2026quality} argue that the correlation coefficient does not measure the information a prediction shares with the presumed truth, synthetic seismograms or well logs, and propose information-theoretic measures, also as training losses. They note that time--depth functions are never exact and that time shifts degrade mainly the higher-frequency part of a comparison. Their measures depend only on value distributions and are therefore insensitive to small shifts, but the timing error itself is neither modelled nor carried into training; their porosity example with five training wells does not describe the tie or treat it as uncertain.
\paragraph{Losses that tolerate temporal misalignment.} \paragraph{Losses that tolerate temporal misalignment.}
Soft-DTW \citep{cuturi2017softdtw} and DILATE \citep{leguen2019dilate} replace the pointwise loss with a smoothed minimum over monotone alignments. Shift-tolerant losses that take the minimum over a set of bulk lags are a simpler variant. These losses use no time anchors, no physical tie model and no prior over warps. Proposition~\ref{prop:ident} shows that, without anchors, the absolute timing they learn is not identified. Learned alignment has also been applied to seismic inputs. \citet{huff2024anglestack} train a CNN on synthetic angle stacks moveout-corrected with true and perturbed velocities and use it to align field angle stacks. There the misaligned quantities are the inputs, and the synthetic targets are aligned by construction. Soft-DTW \citep{cuturi2017softdtw} and DILATE \citep{leguen2019dilate} replace the pointwise loss with a smoothed minimum over monotone alignments. Shift-tolerant losses that take the minimum over a set of bulk lags are a simpler variant. These losses use no time anchors, no physical tie model and no prior over warps. Proposition~\ref{prop:ident} shows that, without anchors, the absolute timing they learn is not identified. Learned alignment has also been applied to seismic inputs. \citet{huff2024anglestack} train a CNN on synthetic angle stacks moveout-corrected with true and perturbed velocities and use it to align field angle stacks. There the misaligned quantities are the inputs, and the synthetic targets are aligned by construction.
@@ -18,7 +18,7 @@ Measurement-error models distinguish classical error, which is independent of th
The spectral effect of random timing errors has long been studied for sampling jitter \citep{balakrishnan1962jitter}. A misregistered well label differs from these cases in where the error enters. Its values are correct, but they are placed at the wrong times. The error acts on the time index, it is correlated along the well, and its effect depends on frequency: it leaves the low frequencies nearly unchanged and blurs the seismic band (Proposition~\ref{prop:blur}). The classical and Berkson structures carry over to the time index, where they bias the learned predictor in opposite directions (Proposition~\ref{prop:tie}). The spectral effect of random timing errors has long been studied for sampling jitter \citep{balakrishnan1962jitter}. A misregistered well label differs from these cases in where the error enters. Its values are correct, but they are placed at the wrong times. The error acts on the time index, it is correlated along the well, and its effect depends on frequency: it leaves the low frequencies nearly unchanged and blurs the seismic band (Proposition~\ref{prop:blur}). The classical and Berkson structures carry over to the time index, where they bias the learned predictor in opposite directions (Proposition~\ref{prop:tie}).
\paragraph{Label uncertainty in learned seismic interpretation.} \paragraph{Label uncertainty in learned seismic interpretation.}
\citet{quesada2024faultlabels} collected fault labels on 400 F3 images from 38 annotators with different expertise and confidence. \citet{mirza2025labelquality} assess the variability of manual salt interpretations together with seismic image quality. \citet{guillon2020gtmetrics} add a tolerance distance to fault and horizon metrics, because thin boundaries cannot be placed exactly. In these works the label is an interpretation of the seismic image itself, the task is classification or segmentation, and the uncertainty is described by annotator disagreement or a spatial tolerance. In our problem the label values come from well logs, and their position on the seismic time axis is what is uncertain. A physical tie model conditioned on anchors gives a posterior for that position. \citet{quesada2024faultlabels} collected fault labels on 400 F3 images from 38 annotators with different expertise and confidence. \citet{mirza2025labelquality} assess the variability of manual salt interpretations together with seismic image quality. \citet{guillon2020gtmetrics} add a tolerance distance to fault and horizon metrics, because thin boundaries cannot be placed exactly and picks of the same boundary by different interpreters differ by a few pixels. The tolerance enters only the evaluation; they name a tolerance-aware training loss as future work. In these works the label is an interpretation of the seismic image itself, the task is classification or segmentation, and the uncertainty is described by annotator disagreement or a spatial tolerance. In our problem the label values come from well logs, and their position on the seismic time axis is what is uncertain. A physical tie model conditioned on anchors gives a posterior for that position.
\paragraph{Position of this work.} \paragraph{Position of this work.}
Table~\ref{tab:positioning} summarizes the comparison. The ingredients are not new: tie posteriors \citep{buland2003bayesianwavelet,gunning2006waveletextractor}, the spectral effect of random timing errors \citep{balakrishnan1962jitter}, the classical and Berkson error structures \citep{carroll2006measurement}, and a likelihood marginalized over label translations \citep{mnih2012aerial}. To our knowledge, in the reviewed literature no work combines them for seismic property prediction. None analyses how tie error in the training labels changes the learned predictor, feeds a tie posterior into training and evaluates the result under known registration error, or derives how accurate the reference at blind wells must be for a comparison of tie methods to detect a difference. The tie posterior itself builds directly on \citet{buland2003bayesianwavelet} and \citet{gunning2006waveletextractor}. Table~\ref{tab:positioning} summarizes the comparison. The ingredients are not new: tie posteriors \citep{buland2003bayesianwavelet,gunning2006waveletextractor}, the spectral effect of random timing errors \citep{balakrishnan1962jitter}, the classical and Berkson error structures \citep{carroll2006measurement}, and a likelihood marginalized over label translations \citep{mnih2012aerial}. To our knowledge, in the reviewed literature no work combines them for seismic property prediction. None analyses how tie error in the training labels changes the learned predictor, feeds a tie posterior into training and evaluates the result under known registration error, or derives how accurate the reference at blind wells must be for a comparison of tie methods to detect a difference. The tie posterior itself builds directly on \citet{buland2003bayesianwavelet} and \citet{gunning2006waveletextractor}.
@@ -34,21 +34,21 @@ Work & DL & Tie & Tie UQ & UQ$\to$train & Reg.\ eval. \\
\midrule \midrule
\citet{prabowo2025f3,tao2025structural,xu2024sts,liu2023lowfrequency,corrales2024seis2rock} & \checkmark & -- & -- & -- & -- \\ \citet{prabowo2025f3,tao2025structural,xu2024sts,liu2023lowfrequency,corrales2024seis2rock} & \checkmark & -- & -- & -- & -- \\
\citet{cordoba2025porosity}\textsuperscript{a} & \checkmark & -- & -- & -- & -- \\ \citet{cordoba2025porosity}\textsuperscript{a} & \checkmark & -- & -- & -- & -- \\
\citet{li2024bpinn}\textsuperscript{a}, \citet{sukar2026uncertainty} & \checkmark & -- & -- & -- & -- \\ \citet{li2024bpinn,sukar2026uncertainty} & \checkmark & -- & -- & -- & -- \\
\citet{rizzuti2024waveletflows,rizzuti2025uhr,lim2025bootnet}\textsuperscript{a} & \checkmark & -- & -- & -- & -- \\ \citet{rizzuti2024waveletflows,rizzuti2025uhr,lim2025bootnet} & \checkmark & -- & -- & -- & -- \\
\citet{ali2025syntheticpseudowells} & \checkmark & -- & avoided & -- & -- \\ \citet{ali2025syntheticpseudowells} & \checkmark & -- & avoided & -- & -- \\
\citet{di2023welltie}\textsuperscript{a}, \citet{li2025cascadedtie} & -- & \checkmark & -- & -- & -- \\ \citet{di2023welltie}\textsuperscript{a}, \citet{li2025cascadedtie}, \citet{dacostasilva2026autotie}\textsuperscript{a} & -- & \checkmark & -- & -- & -- \\
\citet{tschannen2022partialtie} & -- & \checkmark & partial & -- & -- \\ \citet{tschannen2022partialtie} & -- & \checkmark & partial & -- & -- \\
\citet{wu2017multiwelltie} & -- & \checkmark & -- & -- & -- \\ \citet{wu2017multiwelltie,herrera2012automatedtie} & -- & \checkmark & -- & -- & -- \\
\citet{buland2003bayesianwavelet,gunning2006waveletextractor} & -- & \checkmark & \checkmark & -- & -- \\ \citet{buland2003bayesianwavelet,gunning2006waveletextractor} & -- & \checkmark & \checkmark & -- & -- \\
\citet{lim2025awsm}\textsuperscript{a} & -- & \checkmark & \checkmark & -- & -- \\ \citet{lim2025awsm} & -- & \checkmark & \checkmark & -- & -- \\
Soft-DTW, DILATE & generic & soft & -- & -- & -- \\ Soft-DTW, DILATE & generic & soft & -- & -- & -- \\
\citet{mnih2012aerial} & seg. & -- & -- & transl. & tol. \\ \citet{mnih2012aerial} & seg. & -- & -- & transl. & tol. \\
\citet{quesada2024faultlabels}\textsuperscript{a}, \citet{mirza2025labelquality}\textsuperscript{a} & seg. & -- & -- & -- & -- \\ \citet{quesada2024faultlabels}\textsuperscript{a}, \citet{mirza2025labelquality}\textsuperscript{a} & seg. & -- & -- & -- & -- \\
\citet{guillon2020gtmetrics}\textsuperscript{a} & seg. & -- & -- & -- & tol. \\ \citet{guillon2020gtmetrics} & seg. & -- & -- & -- & tol. \\
This work & \checkmark & \checkmark & \checkmark & \checkmark & \checkmark \\ This work & \checkmark & \checkmark & \checkmark & \checkmark & \checkmark \\
\bottomrule \bottomrule
\end{tabular} \end{tabular}
\end{table} \end{table}
\todoblock{(1) SEG and EAGE expanded abstracts 2024--2026 were scanned on 28/10/2026; the ten entries added then are abstract-only (\texttt{refs.bib}, block dated 2026-10-28). Still open: the IMAGE 2026 abstract by Palavicini Gurria et al.\ on well ties and seismic inversion as quantitative quality controls (in the official program, text not retrieved); the DOI and pages of \citet{quesada2024faultlabels}; rerun the novelty search on the submission day and revise ``to our knowledge'' if needed. (2) The 28/10 SEG/EAGE entries were assessed from abstracts only; read the full texts if obtained, otherwise keep the footnote. (Full texts of \citet{chen2024multidimensional}, \citet{li2024bpinn}, \citet{di2023welltie} and \citet{dou2024seismae} cannot be obtained, confirmed 28/10/2026; every use of them above was checked against the abstracts and the footnote stays.) (3) Decide whether to cite the Geophysics 2014 version of Herrera \& van der Baan (not obtained; the 2012 preprint is cited). (4) Check that the ``UQ$\to$train'' column is fair to \citet{sukar2026uncertainty}.} \todoblock{(1) A preliminary novelty scan was run on 02/11/2026 (Crossref, OpenAlex 2025--2026 and web search; queries and hits in \texttt{docs/plan.md} \S12 item 31). It found no work that feeds tie uncertainty into the training of a property predictor; ``to our knowledge'' stands, and \citet{herrera2014semiautomatic}, \citet{dacostasilva2026autotie} and \citet{castagna2026quality} were added (the first two from abstracts only; \citet{castagna2026quality} read in full on 02/11/2026). Rerun the scan on the submission day (13/11/2026). Still open then: the IMAGE 2026 abstract by Palavicini Gurria et al.\ on well ties and seismic inversion as quantitative quality controls (in the official program; on 02/11/2026 no IMAGE 2026 expanded abstract was indexed in Crossref or OpenAlex), and the DOI and pages of \citet{quesada2024faultlabels} (not found on 28/10 or 02/11; otherwise keep the lab-page URL). (2) Entries marked \textsuperscript{a} in Table~\ref{tab:positioning} were assessed from abstracts only; their full texts cannot be obtained (closed 02/11/2026), so the markers stay. Full texts of \citet{lim2025awsm}, \citet{lim2025bootnet}, \citet{li2024bpinn}, \citet{guillon2020gtmetrics}, \citet{rizzuti2024waveletflows} and \citet{rizzuti2025uhr} were obtained on 02/11/2026; every use above was checked against them, the table classifications did not change, and their markers were removed. (Full texts of \citet{chen2024multidimensional}, \citet{di2023welltie} and \citet{dou2024seismae} cannot be obtained, confirmed 28/10/2026; every use of them above was checked against the abstracts.)}

View File

@@ -4,7 +4,7 @@
\subsection{F3 block} \subsection{F3 block}
\label{sec:data:f3} \label{sec:data:f3}
We use the public F3 Demo 2023 release of the F3 block, Dutch sector of the North Sea \todo{dataset citation (dGB Earth Sciences / TNO); licence CC BY-SA 3.0, verify wording}. The post-stack volume covers inlines 100--750 and crosslines 300--1250 at 4\,ms sampling. Four vertical wells have sonic (DT), density (RHOB) and effective porosity (PHIE) logs: F02-1, F03-2, F03-4 and F06-1. The release also contains seven interpreted horizons and time--depth (TD) markers at each well. All learning experiments use the window 600--1100\,ms TWT (126 samples). Tie likelihoods and anchors use the extended window 400--1300\,ms. We use the public F3 Demo 2023 release of the F3 block, Dutch sector of the North Sea, distributed by dGB Earth Sciences as an OpendTect project under a CC BY-SA 3.0 licence \citep{dgb2023f3demo}. The post-stack volume covers inlines 100--750 and crosslines 300--1250 at 4\,ms sampling. Four vertical wells have sonic (DT), density (RHOB) and effective porosity (PHIE) logs: F02-1, F03-2, F03-4 and F06-1. The release also contains seven interpreted horizons and time--depth (TD) markers at each well. All learning experiments use the window 600--1100\,ms TWT (126 samples). Tie likelihoods and anchors use the extended window 400--1300\,ms.
Within the target window, the amplitude spectrum around the wells and over the volume peaks near 60\,Hz with a mean frequency of 49\,Hz. The dominant period is therefore 17--20\,ms. The $-20$\,dB band of the volume spans 4--83\,Hz. Within the target window, the amplitude spectrum around the wells and over the volume peaks near 60\,Hz with a mean frequency of 49\,Hz. The dominant period is therefore 17--20\,ms. The $-20$\,dB band of the volume spans 4--83\,Hz.
@@ -57,10 +57,15 @@ The true time--depth warp of each well is drawn from the warp prior of Section~\
\end{itemize} \end{itemize}
Under the F3 warp prior, Rm5 gives the posterior width closest to F3 (Section~\ref{sec:exp:p2r}). Under the F3 warp prior, Rm5 gives the posterior width closest to F3 (Section~\ref{sec:exp:p2r}).
\paragraph{Misspecification (Experiment~3).}
Study S2 generates the data with a simulator that departs from the model used for registration, which keeps the nominal rock physics, a statistical wavelet with a constant phase, and the warp prior of Section~\ref{sec:method:prior}. There are three axes, each at two levels (Table~\ref{tab:s2}). Rock physics: the DT intercept (matrix slowness) is scaled in each stratigraphic unit by $1 + s\zeta_u$, $\zeta_u \sim \N(0, 1)$, with $s = 0.10$ (L1, about $\pm 18\,\mu$s/m) or $0.15$ (L2). Wavelet: the phase spectrum is half (L1) or all (L2) of the minimum-phase spectrum of the nominal amplitude spectrum; a separate cell, wv\_Q, applies constant-$Q$ attenuation ($Q = 80$ from 400\,ms, with dispersion), which lowers the peak frequency from 59 to 32\,Hz across the window. Drift: the true warps are drawn with scaled prior hyperparameters (bulk-offset standard deviation $\times 3$, which exceeds the value fixed in the registration, drift standard deviation $\times 1.5$ and correlation length $\times 0.5$; L1), or with components outside the prior's family (an 8\,ms step just below Truncation plus jitter with standard deviation 1\,ms and correlation length 8\,ms; L2). The size of a seismic misspecification is measured by its model error: the RMS residual between the clean seismic and the best synthetic in the registration's model family at the true warp, divided by the RMS of the noise at R10. It is 0.23 for the nominal simulator and 1.08--1.93 for the five seismic presets.
The levels were chosen on development realizations 902--905. The declared target for L1 was 0.5--1.0 times the R10 noise, and both L1 levels lie above it. For the phase no milder level exists: a quarter of the minimum-phase spectrum (model error 0.62) already reduced the 90\% warp coverage to 0.25 on development data. For rock physics, milder levels changed the registration too little to be told apart, so the level was set by model error. Uniform errors in the rock-physics coefficients, a constant phase rotation and a shift of the peak frequency are absorbed by the registration's profiled amplitude and constant-phase fit; they were run on development data only, as controls. At Rm5 the noise RMS is 1.78 times that of the signal and the model errors are 0.22--0.34 of the noise, so the protocol declared in advance that registration at Rm5 should be unaffected.
\subsection{Volve field} \subsection{Volve field}
\label{sec:data:volve} \label{sec:data:volve}
The second field dataset is Volve (Norwegian North Sea), released by Equinor under a CC BY-NC-SA 4.0 licence \todo{dataset citation (Equinor Volve data village)}. Its role is to break the label structure of F3. The computed effective porosity PHIF of the operator's petrophysical interpretation is driven by density, not by sonic: within each well its correlation with RHOB is $-0.92$ to $-0.99$, RHOB and NPHI explain 84--98\% of its variance, and adding DT raises this by at most 0.9 percentage points. Six wells have DT, RHOB, NPHI and PHIF: F-1, F-1 A, F-1 B, F-11 A, F-11 T2 and F-12. All six are deviated (maximum inclination 30--82$^\circ$; 4--54$^\circ$ over the labelled interval), and they share one platform. F-1 A and F-1 B leave the F-1 borehole at 2587\,m MD, and F-11 A leaves F-11 T2 at about 2580\,m MD, so the wells form three slot groups, \{F-1, F-1 A, F-1 B\}, \{F-11 A, F-11 T2\} and \{F-12\}, whose members share the hole above the kick-off. The second field dataset is Volve (Norwegian North Sea), released by Equinor in 2018 \citep{equinor2018volve}; the licence files of the release name CC BY-NC-SA 4.0. Its role is to break the label structure of F3. The computed effective porosity PHIF of the operator's petrophysical interpretation is driven by density, not by sonic: within each well its correlation with RHOB is $-0.92$ to $-0.99$, RHOB and NPHI explain 84--98\% of its variance, and adding DT raises this by at most 0.9 percentage points. Six wells have DT, RHOB, NPHI and PHIF: F-1, F-1 A, F-1 B, F-11 A, F-11 T2 and F-12. All six are deviated (maximum inclination 30--82$^\circ$; 4--54$^\circ$ over the labelled interval), and they share one platform. F-1 A and F-1 B leave the F-1 borehole at 2587\,m MD, and F-11 A leaves F-11 T2 at about 2580\,m MD, so the wells form three slot groups, \{F-1, F-1 A, F-1 B\}, \{F-11 A, F-11 T2\} and \{F-12\}, whose members share the hole above the kick-off.
\paragraph{Seismic and geometry.} \paragraph{Seismic and geometry.}
We use the post-stack ST10010 full-angle stack (3--41$^\circ$), a 2011 depth migration converted to time, at 4\,ms sampling. Its trace headers carry an invalid time scalar that standard readers apply to the start time, which shifts every sample 8\,ms late. We use the start time of the text header (4\,ms) and checked it against five interpreted horizons: the amplitude extremum along each falls at a lag of 0 to $+2$\,ms. Trajectories come from the operator's definitive surveys; recomputing them by minimum curvature reproduces the listed TVD within 0.01\,m. The seismic input of a well is a $3\times3$ patch of traces interpolated bilinearly along the deviated path at the time given by its time--depth relation, because a vertical trace at one bin differs from the path composite by a relative RMS of 0.19--0.61 over the labelled interval. Learning uses the window 2400--2900\,ms (126 samples) and tie likelihoods the extended window 2000--3200\,ms. We use the post-stack ST10010 full-angle stack (3--41$^\circ$), a 2011 depth migration converted to time, at 4\,ms sampling. Its trace headers carry an invalid time scalar that standard readers apply to the start time, which shifts every sample 8\,ms late. We use the start time of the text header (4\,ms) and checked it against five interpreted horizons: the amplitude extremum along each falls at a lag of 0 to $+2$\,ms. Trajectories come from the operator's definitive surveys; recomputing them by minimum curvature reproduces the listed TVD within 0.01\,m. The seismic input of a well is a $3\times3$ patch of traces interpolated bilinearly along the deviated path at the time given by its time--depth relation, because a vertical trace at one bin differs from the path composite by a relative RMS of 0.19--0.61 over the labelled interval. Learning uses the window 2400--2900\,ms (126 samples) and tie likelihoods the extended window 2000--3200\,ms.

View File

@@ -11,7 +11,7 @@ $t$ is seismic two-way time, $X$ the seismic input around a well, and $y(t)$ the
\begin{proposition}[Blur] \begin{proposition}[Blur]
\label{prop:blur} \label{prop:blur}
Assume (A1) that for every $t$, $\delta(t)$ is independent of $(X, y(\cdot))$ with distribution $p_t$, and (A2) that $\E[y(t)^2] < \infty$. Then the MSE-optimal predictor of the observed label is Assume (A1) that for every $t$, $\delta(t)$ is independent of $(X, y(\cdot))$ with distribution $p_t$, and (A2) that $\sup_t\E[y(t)^2] < \infty$. Then the MSE-optimal predictor of the observed label is
\begin{equation} \begin{equation}
\hat y^\star(t) = \E[\tilde y(t)\mid X] = \int p_t(d)\, m(t+d)\dd d . \hat y^\star(t) = \E[\tilde y(t)\mid X] = \int p_t(d)\, m(t+d)\dd d .
\end{equation} \end{equation}
@@ -87,18 +87,18 @@ with Gaussian log-likelihood $\mathcal L_w$ over windows and anchors $(z_{wk}, t
\begin{proposition}[Identifiability] \begin{proposition}[Identifiability]
\label{prop:ident} \label{prop:ident}
Assume (B) that the model class is closed under output shifts: for each $\theta$ and each admissible $\beta$ there is $\theta'$ with $\mu_{\theta'} = T_\beta \mu_\theta$ and $\sigma_{\theta'} = T_\beta\sigma_\theta$. Then, up to window-edge effects: Assume (B) that the model class is closed under output shifts: for each $\theta$ and each shift $\beta$ by a whole number of samples with $|\beta| \le \beta_{\max}$ there is $\theta'$ with $\mu_{\theta'} = T_\beta \mu_\theta$ and $\sigma_{\theta'} = T_\beta\sigma_\theta$. Then, up to window-edge effects:
\begin{enumerate} \begin{enumerate}
\item[(a)] without anchors, with a flat prior on $b$ and no seismic tie term, $\Phi(\theta', \mathbf u + \beta e_b) = \Phi(\theta, \mathbf u)$, so the objective has a ridge in $\beta$ shared by all wells; \item[(a)] without anchors, with a flat prior on $b$ and no seismic tie term, $\Phi(\theta', \mathbf u + \beta e_b) = \Phi(\theta, \mathbf u)$, so the objective has a ridge in $\beta$ shared by all wells;
\item[(b)] a prior $b_w \sim \N(0, \sigma_b^2)$ adds curvature $N/\sigma_b^2$ along the ridge; \item[(b)] a prior $b_w \sim \N(0, \sigma_b^2)$ adds curvature $N/\sigma_b^2$ along the ridge;
\item[(c)] anchors with finite $\sigma_a$ add curvature $\sum_w K_w/\sigma_a^2$, where $K_w$ is the number of anchors at well $w$, so that \item[(c)] anchors with finite $\sigma_a$ add curvature $\sum_w K_w/\sigma_a^2$, where $K_w$ is the number of anchors at well $w$, so that the spread of $\beta$ along the ridge, with the other parameters held fixed, is
\begin{equation} \begin{equation}
\sd(\beta) \approx \Big(\frac{\sum_w K_w}{\sigma_a^2} + \frac{N}{\sigma_b^2}\Big)^{-1/2} \approx \frac{\sigma_a}{\sqrt{\sum_w K_w}} . \sd(\beta) \approx \Big(\frac{\sum_w K_w}{\sigma_a^2} + \frac{N}{\sigma_b^2}\Big)^{-1/2} \approx \frac{\sigma_a}{\sqrt{\sum_w K_w}} .
\end{equation} \end{equation}
\end{enumerate} \end{enumerate}
\end{proposition} \end{proposition}
With 4 wells of 16 anchors at $\sigma_a = 7$\,ms, $\sd(\beta) \approx 0.9$\,ms. With only the prior $\sigma_b = 50$\,ms, $\sd(\beta) \approx 50/\sqrt N$, that is 35\,ms for $N = 2$ and 12.5\,ms for $N = 16$. A common shift $\beta$ multiplies the band-limited correlation at frequency $f$ by $\cos(2\pi f\beta)$, and $\cos(2\pi\cdot 20\,\mathrm{Hz}\cdot 12.5\,\mathrm{ms}) = 0$. Assumption (B) holds exactly for fully convolutional networks with a wide enough last layer and approximately for the CNN--GRU used here. With 4 wells of 16 anchors at $\sigma_a = 7$\,ms, $\sd(\beta) \approx 0.9$\,ms. With only the prior $\sigma_b = 50$\,ms, $\sd(\beta) \approx 50/\sqrt N$, that is 35\,ms for $N = 2$ and 12.5\,ms for $N = 16$. A common shift $\beta$ multiplies the band-limited correlation at frequency $f$ by $\cos(2\pi f\beta)$, and $\cos(2\pi\cdot 20\,\mathrm{Hz}\cdot 12.5\,\mathrm{ms}) = 0$. The marginal spread, which also integrates over the drift of each well, is at least as large. Assumption (B) holds exactly, up to window edges, for a fully convolutional network whose last-layer kernel extends at least $\beta_{\max}$ samples beyond the weights it uses on each side, and approximately for the CNN--GRU used here.
\paragraph{The seismic tie term.} \paragraph{The seismic tie term.}
Seismic is observed on a fixed time axis, so a tie likelihood that compares the seismic with a warped synthetic is not invariant to $\beta$. In principle it pins absolute time. In practice a small shift trades off against a constant wavelet phase rotation: the two coincide at $f_0 = \psi/(2\pi\beta)$ and differ by $2\pi(f - f_0)\beta$ elsewhere. For $\beta = 4$\,ms the largest phase difference over $\pm 30$\,Hz around $f_0$ is only about $43^\circ$. Information about $\beta$ thus comes from the bandwidth, not the centre frequency. Seismic is observed on a fixed time axis, so a tie likelihood that compares the seismic with a warped synthetic is not invariant to $\beta$. In principle it pins absolute time. In practice a small shift trades off against a constant wavelet phase rotation: the two coincide at $f_0 = \psi/(2\pi\beta)$ and differ by $2\pi(f - f_0)\beta$ elsewhere. For $\beta = 4$\,ms the largest phase difference over $\pm 30$\,Hz around $f_0$ is only about $43^\circ$. Information about $\beta$ thus comes from the bandwidth, not the centre frequency.
@@ -136,7 +136,7 @@ Assume (A2) for $y$ and $\tilde y$.
If $p_t$ and $q_t$ do not depend on $t$, then, averaged over the window and up to edge terms, the point label has the larger conditional variance under (a) and the smaller under (b). If they depend on neither $t$ nor $X$, then $\tilde m$ is $m$ filtered by $P$ under (a), and $m$ is $\tilde m$ filtered by $Q$ under (b). For zero-mean Gaussian errors with variance $\sigma^2$, the transfer from $m$ to $\tilde m$ is $e^{-2\pi^2\sigma^2 f^2}$ under (a) and $e^{+2\pi^2\sigma^2 f^2}$ under (b). If $p_t$ and $q_t$ do not depend on $t$, then, averaged over the window and up to edge terms, the point label has the larger conditional variance under (a) and the smaller under (b). If they depend on neither $t$ nor $X$, then $\tilde m$ is $m$ filtered by $P$ under (a), and $m$ is $\tilde m$ filtered by $Q$ under (b). For zero-mean Gaussian errors with variance $\sigma^2$, the transfer from $m$ to $\tilde m$ is $e^{-2\pi^2\sigma^2 f^2}$ under (a) and $e^{+2\pi^2\sigma^2 f^2}$ under (b).
\end{proposition} \end{proposition}
Structure (a) is the classical structure of measurement-error models, in which the error is independent of the true value. Structure (b) is the Berkson structure, in which the error is independent of the assigned value \citep{berkson1950two,carroll2006measurement}. Here the error lies in the time index of the label, and the two structures bias the learned predictor in opposite directions. Under (a) the point label blurs the optimal predictor and widens the learned variance. Under (b) it sharpens the predictor and narrows the variance. Structure (b) is the natural idealization for a tie computed as a posterior mean, $\hat u = \E[u^\star\mid D]$. Then $\E[u^\star - \hat u\mid D] = 0$ by construction, and in a linear-Gaussian model $u^\star - \hat u$ is independent of $D$. For the bulk offset $b$ in \eqref{eq:warp}, the time error equals the posterior error of $b$ and inherits this property; for the drift it does so approximately, when the posterior is narrow. A tie fitted in another way, for example by maximizing a synthetic--seismic correlation, can have either structure or neither. On synthetic data the two can be told apart: for the bulk offset, classical error means $\Cov(\hat b - b^\star, b^\star) = 0$, and Berkson error means $\Cov(b^\star - \hat b, \hat b) = 0$. Structure (a) is the classical structure of measurement-error models, in which the error is independent of the true value. Structure (b) is the Berkson structure, in which the error is independent of the assigned value \citep{berkson1950two,carroll2006measurement}. Here the error lies in the time index of the label, and the two structures bias the learned predictor in opposite directions. Under (a) the point label blurs the optimal predictor and widens the learned variance. Under (b) it sharpens the predictor and narrows the variance. Structure (b) is the natural idealization for a tie computed as a posterior mean, $\hat u = \E[u^\star\mid D]$. Then $\E[u^\star - \hat u\mid D] = 0$ by construction, and in a linear-Gaussian model $u^\star - \hat u$ is independent of $D$. For the bulk offset $b$ in \eqref{eq:warp}, the time error equals the posterior error of $b$ and inherits this property; for the drift it does so approximately, when the posterior is narrow. A tie fitted in another way, for example by maximizing a synthetic--seismic correlation, can have either structure or neither. On synthetic data the two can be told apart: for the bulk offset, classical error implies $\Cov(\hat b - b^\star, b^\star) = 0$, and Berkson error implies $\Cov(b^\star - \hat b, \hat b) = 0$.
A bank of labels removes the dependence on a single tie when it represents the posterior correctly. A bank of labels removes the dependence on a single tie when it represents the posterior correctly.
@@ -150,18 +150,18 @@ Call a bank $\{(u_s, \pi_s)\}$ calibrated if, for every integrable $G$, $\sum_s
Hence the $\lambda \to 0$ limit of RML (Lemma~\ref{lem:sandwich}) has the population minimizer of training on the true labels, $\mu = m$ and $\sigma^2 = \Var(y\mid X)$, and MSE on the mean label has the population minimizer $\mu = m$. Hence the $\lambda \to 0$ limit of RML (Lemma~\ref{lem:sandwich}) has the population minimizer of training on the true labels, $\mu = m$ and $\sigma^2 = \Var(y\mid X)$, and MSE on the mean label has the population minimizer $\mu = m$.
\end{proposition} \end{proposition}
Calibration is an idealization; it holds for an exact posterior sample as $S \to \infty$. Under it, marginalizing over the posterior removes the population bias of both structures. The mean warp does not share this property. \mPM{} trains on the label at the mean warp $\bar u$, not on the mean label. Expanding $y^{u}$ around $\bar u = \sum_s\pi_s u_s$, Calibration is an idealization; it holds for an exact posterior sample as $S \to \infty$. Under it, marginalizing over the posterior removes the population bias of both structures. The mean warp does not share this property. \mPM{} trains on the label at the mean warp $\bar u$, not on the mean label. Expanding $y^{u}$ formally around $\bar u = \sum_s\pi_s u_s$,
\begin{equation*} \begin{equation*}
\bar y - y^{\bar u} = \tfrac12 \sum_s \pi_s\, (u_s - \bar u)^\top \nabla_u^2 y^{\bar u}\, (u_s - \bar u) + O\big(\|u_s - \bar u\|^3\big), \bar y - y^{\bar u} = \tfrac12 \sum_s \pi_s\, (u_s - \bar u)^\top \nabla_u^2 y^{\bar u}\, (u_s - \bar u) + O\Big(\sum_s \pi_s\|u_s - \bar u\|^3\Big),
\end{equation*} \end{equation*}
so the two labels agree to first order in the posterior spread. If the time error of the mean warp has structure (b), the population optimum of \mPM{} is sharpened by $1/Q$, while that of the mean label is exact. so the two labels agree to first order in the posterior spread. If the time error of the mean warp has structure (b), the population optimum of \mPM{} is sharpened by $1/Q$, while that of the mean label is exact.
\begin{corollary}[Two modes] \begin{corollary}[Two modes]
\label{cor:twomode} \label{cor:twomode}
Let the error ($\delta$ under (a), $\varepsilon$ under (b)) be constant over the window and equal to $\pm\Delta/2$ with probability $\frac12$ each, independently of $X$. Then $P(f) = Q(f) = \cos(\pi f\Delta)$, and under either structure the transfer from $m$ to $\tilde m$ is negative for $1/(2\Delta) < |f| < 3/(2\Delta)$: there the point label trains the network towards the wrong sign. A Gaussian error with the same variance $\Delta^2/4$ has $P(f) = e^{-\pi^2\Delta^2f^2/2} > 0$ at every frequency. The mean label of a calibrated bank has transfer 1. Under (a), a bank of the point label shifted by $\pm\Delta/2$ with equal weights has transfer $\cos^2(\pi f\Delta) \ge 0$. Let the error ($\delta$ under (a), $\varepsilon$ under (b)) be constant over the window and equal to $\pm\Delta/2$ with probability $\frac12$ each, independently of $(X, y)$ under (a) and of $D$ under (b). Then $P(f) = Q(f) = \cos(\pi f\Delta)$, and under either structure the transfer from $m$ to $\tilde m$ is negative for $1/(2\Delta) < |f| < 3/(2\Delta)$: there the point label trains the network towards the wrong sign. A Gaussian error with the same variance $\Delta^2/4$ has $P(f) = e^{-\pi^2\Delta^2f^2/2} > 0$ at every frequency. The mean label of a calibrated bank has transfer 1. Under (a), take the bank of the point label shifted by $\pm\Delta/2$ with equal weights. The population optimum of MSE on its mean label, which is also that of RML on this bank as $\lambda \to 0$, has transfer $\cos^2(\pi f\Delta) \ge 0$. This bank contains the label at the true warp, but it is not calibrated: its equal weights are not the posterior probabilities of its two members.
\end{corollary} \end{corollary}
The phase reversal is a property of multimodal errors that a Gaussian summary hides. If the two modes are one dominant period apart, $\Delta = 1/f_0$, the reversed band is $f_0/2 < |f| < 3f_0/2$. The F3 seismic, from which the D2 wavelet is estimated, peaks near 60\,Hz (Section~\ref{sec:data:f3}), which gives 30--90\,Hz. Cycle skipping produces errors of this kind, and at $c = 2$ the SMC posterior is multimodal (Section~\ref{sec:method:posterior}). In this example, a bank centred on the point label removes the reversal only by attenuating the band further. The phase reversal is a property of multimodal errors that a Gaussian summary hides. If the two modes are one dominant period apart, $\Delta = 1/f_0$, the first reversed band is $f_0/2 < |f| < 3f_0/2$. The F3 seismic, from which the D2 wavelet is estimated, peaks near 60\,Hz (Section~\ref{sec:data:f3}), which gives 30--90\,Hz. Cycle skipping produces errors of this kind, and at $c = 2$ the SMC posterior is multimodal (Section~\ref{sec:method:posterior}). In this example, a bank centred on the point label removes the reversal only by attenuating the band further.
\begin{remark}[$\lambda > 0$] \begin{remark}[$\lambda > 0$]
\label{rem:lambda} \label{rem:lambda}
@@ -196,16 +196,16 @@ Let a method predict a mean $\mu$ and a variance $s^2$ at every test sample. For
\label{prop:coverage} \label{prop:coverage}
\begin{enumerate} \begin{enumerate}
\item[(a)] For any methods $j$ and $O$, $\xi_j - \xi_O = (\Delta v - \xi_O\,\Delta w)/w_j$, with $\Delta v = v_j - v_O$ and $\Delta w = w_j - w_O$. \item[(a)] For any methods $j$ and $O$, $\xi_j - \xi_O = (\Delta v - \xi_O\,\Delta w)/w_j$, with $\Delta v = v_j - v_O$ and $\Delta w = w_j - w_O$.
\item[(b)] Let $y$ be stationary, and let (A1) hold with real $0 \le P \le 1$. Compare the point label at its population optimum ($\mu = \tilde m$, $s^2 = \Var(\tilde y\mid X)$) with the oracle at its optimum ($\mu = m$, $s^2 = \Var(y\mid X)$). Then $\xi_O = 1$ and \item[(b)] Let $m$ and $y$ be jointly stationary, and let (A1) hold with $p_t \equiv p$ and real $0 \le P \le 1$. Compare the point label at its population optimum ($\mu = \tilde m$, $s^2 = \Var(\tilde y\mid X)$) with the oracle at its optimum ($\mu = m$, $s^2 = \Var(y\mid X)$). Then $\xi_O = 1$ and
\begin{equation*} \begin{equation*}
\xi_j - \xi_O = \frac{2}{w_j}\int P(1 - P)\, S_m\dd f \ \ge 0 . \xi_j - \xi_O = \frac{2}{w_j}\int P(1 - P)\, S_m\dd f \ \ge 0 .
\end{equation*} \end{equation*}
\item[(c)] Under structure (b) of Proposition~\ref{prop:tie}, with $q_t$ independent of $t$ and $y$ stationary, the point label at its population optimum has $\xi_j \le 1$. A calibrated bank has $\xi_j = 1$. \item[(c)] Under structure (b) of Proposition~\ref{prop:tie}, with $q_t$ independent of $t$ and $y$ stationary, the point label at its population optimum has $\xi_j \le 1$. A calibrated bank at the $\lambda \to 0$ population optimum of Proposition~\ref{prop:bank} has $\xi = 1$.
\end{enumerate} \end{enumerate}
If $y - \mu = sZ/\sqrt{\xi}$ with $Z$ standard normal and independent of $s$, the interval $\mu \pm z s$ covers with probability $2\Phi(z\sqrt{\xi}) - 1$, which increases with $\xi$. If $y - \mu = sZ/\sqrt{\xi}$ with $Z$ standard normal and independent of $s$, the interval $\mu \pm z s$ covers with probability $2\Phi(z\sqrt{\xi}) - 1$, which increases with $\xi$.
\end{proposition} \end{proposition}
Part (a) is an identity and holds for any finite ensemble. A method covers more than the Oracle when its predicted variance exceeds the Oracle's by more than $\xi_O$ times its excess squared error. Parts (b) and (c) describe the population limit. There, classical tie error widens the intervals of a point-label method, Berkson error narrows them, and a calibrated bank matches the oracle. A finite ensemble can be far from this limit, and in our experiments every ensemble is (Section~\ref{sec:exp:p2r}). Part (a) is an identity and holds for any finite ensemble. A method covers more than the Oracle when its predicted variance exceeds the Oracle's by more than $\xi_O$ times its excess squared error. Parts (b) and (c) describe the population limit, for the bank at $\lambda \to 0$. There, classical tie error widens the intervals of a point-label method, Berkson error narrows them, and a calibrated bank matches the oracle. A finite ensemble can be far from this limit, and in our experiments every ensemble is (Section~\ref{sec:exp:p2r}).
\subsection{Scoring against a misregistered reference} \subsection{Scoring against a misregistered reference}
\label{sec:theory:ref} \label{sec:theory:ref}
@@ -225,13 +225,13 @@ For a symmetric error, $0 \le 1 - Q_r \le 2$, so the reference penalizes in-band
\begin{corollary}[Tolerance] \begin{corollary}[Tolerance]
\label{cor:tolerance} \label{cor:tolerance}
For two methods $A$ and $B$, let $G$ be the true band-MSE advantage of $A$ and $G_r$ the advantage measured against $y_{\mathrm{ref}}$. Then $G_r - G = 2\int_{|f|\ge f_c}\operatorname{Re}\big[(1 - Q_r)(S_{\hat y_B y} - S_{\hat y_A y})\big]\dd f$. Let $\hat y_A = Hm$ and $\hat y_B = HPm$, with real filters $0 \le H, P \le 1$: $A$ learns the oracle and $B$ the blurred optimum of (a), both shrunk by the same finite-sample factor $H$. Then For two methods 1 and 2, let $G$ be the true band-MSE advantage of method 1 and $G_r$ the advantage measured against $y_{\mathrm{ref}}$. Then $G_r - G = 2\int_{|f|\ge f_c}\operatorname{Re}\big[(1 - Q_r)(S_{\hat y_2 y} - S_{\hat y_1 y})\big]\dd f$. Let $\hat y_1 = Hm$ and $\hat y_2 = HPm$, with real filters $0 \le H, P \le 1$: method 1 learns the oracle and method 2 the blurred optimum of (a), both shrunk by the same finite-sample factor $H$. Then
\begin{equation*} \begin{equation*}
G = \int_{|f|\ge f_c} H(1 - P)\big[2 - H(1 + P)\big] S_m\dd f \ \ge 0, G = \int_{|f|\ge f_c} H(1 - P)\big[2 - H(1 + P)\big] S_m\dd f \ \ge 0,
\qquad \qquad
G_r = \int_{|f|\ge f_c} H(1 - P)\big[2Q_r - H(1 + P)\big] S_m\dd f . G_r = \int_{|f|\ge f_c} H(1 - P)\big[2Q_r - H(1 + P)\big] S_m\dd f .
\end{equation*} \end{equation*}
For $H = 1$ and zero-mean Gaussian errors with standard deviations $\sigma$ and $\sigma_r$, $2Q_r - 1 - P = 2\pi^2f^2(\sigma^2 - 2\sigma_r^2) + O(f^4)$, so to leading order the measured advantage has the sign of the true one only if $\sigma_r < \sigma/\sqrt2$. For $H = 1$ and zero-mean Gaussian errors with standard deviations $\sigma$ and $\sigma_r$, $2Q_r - 1 - P = 2\pi^2f^2(\sigma^2 - 2\sigma_r^2) + O(f^4)$, so the measured advantage can have the sign of the true one only if $\sigma_r < \sigma/\sqrt2$. The condition is necessary at every frequency, not only to leading order, and it is not sufficient: the measured advantage changes sign at a reference error below $\sigma/\sqrt2$.
\end{corollary} \end{corollary}
Shrinkage relaxes this condition, because $2Q_r - H(1 + P)$ grows as $H$ decreases. If $B$ is over-sharp instead, as under (b), with $\hat y_B = HKm$ and $K \ge 1$, then $G_r - G = 2\int_{|f|\ge f_c} H(K - 1)(1 - Q_r)S_m\dd f \ge 0$, and the reference exaggerates the advantage of $A$. Independence between $\varepsilon_r$ and the prediction is plausible for a reference from check shots or a vertical seismic profile. A reference tied by synthetic--seismic matching depends on the same seismic as the prediction, and its error adds a covariance term to \eqref{eq:refbias}. Section~\ref{sec:exp:detect} estimates how many blind wells a comparison needs at a given reference error. Shrinkage relaxes this condition, because $2Q_r - H(1 + P)$ grows as $H$ decreases. If method 2 is over-sharp instead, as under (b), with $\hat y_2 = HKm$ and $K \ge 1$, then $G_r - G = 2\int_{|f|\ge f_c} H(K - 1)(1 - Q_r)S_m\dd f \ge 0$, and the reference exaggerates the advantage of method 1. Independence between $\varepsilon_r$ and the prediction is plausible for a reference from check shots or a vertical seismic profile. A reference tied by synthetic--seismic matching depends on the same seismic as the prediction, and its error adds a covariance term to \eqref{eq:refbias}. Section~\ref{sec:exp:detect} estimates how many blind wells a comparison needs at a given reference error.

View File

@@ -90,7 +90,7 @@ With a bank of the point-tie label shifted by every integer lag in $\pm K$ sampl
\begin{lemma}[Soft-DTW] \begin{lemma}[Soft-DTW]
\label{lem:sdtw} \label{lem:sdtw}
Let $D_{ij} = -\log\N(y_j; \mu_i, \sigma_i^2)$, let $\mathcal P$ be the set of monotone alignment paths from $(0,0)$ to $(n-1,n-1)$ within a Sakoe--Chiba band, and let $\langle A, D\rangle_w$ be the path cost with symmetric step weights (diagonal steps counted twice; \citealp{sakoe1978dp}). For soft-DTW with these steps \citep{cuturi2017softdtw}, Let $D_{ij} = -\log\N(y_j; \mu_i, \sigma_i^2)$, let $\mathcal P$ be the set of monotone alignment paths from $(0,0)$ to $(n-1,n-1)$ within a Sakoe--Chiba band, and let $\langle A, D\rangle_w$ be the path cost with symmetric step weights (diagonal steps and the start cell counted twice; \citealp{sakoe1978dp}). For soft-DTW with these steps \citep{cuturi2017softdtw},
\begin{equation} \begin{equation}
\frac{\mathrm{sDTW}_\gamma(D)}{2n} = \RML_{\lambda = 2/\gamma}\Big[\text{bank} = \mathcal P,\ \pi \text{ uniform},\ \ell_A = -\tfrac12\langle A, D\rangle_w\Big] - \frac{\gamma}{2n}\log|\mathcal P| . \frac{\mathrm{sDTW}_\gamma(D)}{2n} = \RML_{\lambda = 2/\gamma}\Big[\text{bank} = \mathcal P,\ \pi \text{ uniform},\ \ell_A = -\tfrac12\langle A, D\rangle_w\Big] - \frac{\gamma}{2n}\log|\mathcal P| .
\end{equation} \end{equation}
@@ -101,14 +101,14 @@ The last term does not depend on $\theta$. On the diagonal path, $\ell_A$ equals
\subsection{Network and training} \subsection{Network and training}
\label{sec:method:train} \label{sec:method:train}
All learned methods share one backbone and differ only in their labels and loss. The input is a $3\times3$ trace patch around the well (nine channels), z-scored per channel within each well. Three dilated 1-D convolutions (kernel 5, dilations 1, 2 and 4, 64 channels) feed a two-layer bidirectional GRU. A $1\times1$ head with a $1\times1$ skip connection outputs $\mu$ and $\sigma$ (softplus, $\sigma \ge 10^{-3}$). Dropout is 0.05. We train with Adam (learning rate $5\times10^{-3}$, gradient clipping at 5) on full batches of all training wells. Losses are computed on 64-sample windows starting at samples $0, 2, \dots, 62$ of the 126-sample main window. Labels are standardized by the mean and standard deviation of the anti-aliased log over the training wells. These statistics do not depend on the tie. The number of iterations is selected separately for each method from $\{125, 250, 500, 1000, 2000\}$ by total RMSE on the development realizations; on F3 it is selected by inner validation (Appendix~\ref{sec:exp:f3}). Every method has the same candidate set, and band metrics are not used for selection. Ensembles average five seeds (on F3, three inner models $\times$ five seeds), with $\mu = \overline{\mu_s}$ and $\sigma^2 = \overline{\sigma_s^2} + \Var_s \mu_s$. All learned methods share one backbone and differ only in their labels and loss; study S4 of Experiment~3 adds a second. The input is a $3\times3$ trace patch around the well (nine channels), z-scored per channel within each well. Three dilated 1-D convolutions (kernel 5, dilations 1, 2 and 4, 64 channels) feed a two-layer bidirectional GRU. A $1\times1$ head with a $1\times1$ skip connection outputs $\mu$ and $\sigma$ (softplus, $\sigma \ge 10^{-3}$). Dropout is 0.05. We train with Adam (learning rate $5\times10^{-3}$, gradient clipping at 5) on full batches of all training wells. Losses are computed on 64-sample windows starting at samples $0, 2, \dots, 62$ of the 126-sample main window. Labels are standardized by the mean and standard deviation of the anti-aliased log over the training wells. These statistics do not depend on the tie. The number of iterations is selected separately for each method from $\{125, 250, 500, 1000, 2000\}$ by total RMSE on the development realizations; on F3 it is selected by inner validation (Appendix~\ref{sec:exp:f3}). Every method has the same candidate set, and band metrics are not used for selection. The second backbone, a TCN, has no recurrence: four dilated 1-D convolutions (kernel 5, dilations 1, 2, 4 and 8, 64 channels, ReLU, the same dropout) and the same output head without the skip connection. Its iterations were selected by the same rule on development realizations 902--905 (R10, $c = 1$). Every method selected 125, the smallest candidate, and the candidate set was not extended. Ensembles average five seeds (on F3, three inner models $\times$ five seeds), with $\mu = \overline{\mu_s}$ and $\sigma^2 = \overline{\sigma_s^2} + \Var_s \mu_s$.
\subsection{Compared methods} \subsection{Compared methods}
\label{sec:method:baselines} \label{sec:method:baselines}
Table~\ref{tab:methods} lists the methods. In the language of Lemmas~\ref{lem:s1}--\ref{lem:sdtw}, the B3 family is RML with $S = 1$ at different point ties. B4 is RML with anchor-free banks, and M1, M2 and \mRML{} are RML with anchor-conditioned banks. Table~\ref{tab:methods} lists the methods. In the language of Lemmas~\ref{lem:s1}--\ref{lem:sdtw}, the B3 family is RML with $S = 1$ at different point ties. B4 is RML with anchor-free banks, and M1, M2 and \mRML{} are RML with anchor-conditioned banks.
\begin{table}[t] \begin{table}[!tbp]
\centering \centering
\caption{Compared methods. All learned methods use the backbone of Section~\ref{sec:method:train}. Bank: labels entering \eqref{eq:rml}.} \caption{Compared methods. All learned methods use the backbone of Section~\ref{sec:method:train}. Bank: labels entering \eqref{eq:rml}.}
\label{tab:methods} \label{tab:methods}
@@ -143,12 +143,18 @@ M1 & 64 anchor-posterior warps, uniform $\pi$ & $\RML_{1/\tau_c}$ \\
M2 & as M1, tempered physical weights & $\RML_{1/\tau_c}$ \\ M2 & as M1, tempered physical weights & $\RML_{1/\tau_c}$ \\
\mRML & 64 SMC particles, uniform $\pi$ & $\RML_{1/\tau_c}$ \\ \mRML & 64 SMC particles, uniform $\pi$ & $\RML_{1/\tau_c}$ \\
\midrule \midrule
\multicolumn{3}{l}{\emph{Benchmark additions (Experiment~3)$^{\ddagger}$}} \\
Ctl-GP & 64 warps $\bar u + \eta$, $\eta$ Gaussian with the covariance of the SMC particles (monotone draws only), uniform $\pi$ & $\RML_{1/\tau_c}$ \\
PM2 & two-mode error: label at $u^\star + s\Delta/2$, $s = \pm 1$ drawn per well & NLL \\
BK2 & $\{u^\star, u^\star + s\Delta\}$, $\pi = (\frac12, \frac12)$ & $\RML_{1/\tau_c}$ \\
HM2 & as BK2 & $\RML_\infty$ \\
\midrule
B5 & five-seed ensemble of B3b & NLL \\ B5 & five-seed ensemble of B3b & NLL \\
\bottomrule \bottomrule
\end{tabular} \end{tabular}
\smallskip \smallskip
\footnotesize $^{\dagger}$Labels as B3b; deterministic output. Loss: Huber regression loss $+\,0.60$ correlation $+\,0.05$ first-difference $+\,0.10$ standardized-shape $+\,0.10$ variance-matching $+\,0.20$ best-shift MSE (minimum over shifts of $\pm 8$ samples). \footnotesize $^{\dagger}$Labels as B3b; deterministic output. Loss: Huber regression loss $+\,0.60$ correlation $+\,0.05$ first-difference $+\,0.10$ standardized-shape $+\,0.10$ variance-matching $+\,0.20$ best-shift MSE (minimum over shifts of $\pm 8$ samples). $^{\ddagger}$Study S4 also trains the Oracle, B3b, B3c, B3c-R, \mPM{} and \mRML{} with the TCN backbone (suffix -TCN).
\end{table} \end{table}
\subsection{Metrics} \subsection{Metrics}

View File

@@ -1,7 +1,7 @@
\section{Experiments} \section{Experiments}
\label{sec:experiments} \label{sec:experiments}
We ran two pre-registered synthetic experiments, in order, and then pre-registered field tests on F3 and Volve (Section~\ref{sec:exp:scope}; details in Appendix~\ref{app:field}). Before each main run, the protocol (grid, methods, iteration budgets, pass rules) was locked by a SHA-256 hash, and the scripts refuse to run if the hash does not match. The two synthetic protocols were also committed and tagged in version control before their main runs. The field protocols were committed only after their runs, so for them the record of timing is the time stamp inside the lock file (Appendix~\ref{app:field}). In the synthetic experiments, every design choice was made on two development realizations (900 and 901), which are never used for results. Test labels were never used to choose a shift, checkpoint or hyperparameter. We ran two pre-registered synthetic experiments, in order, then pre-registered field tests on F3 and Volve (Section~\ref{sec:exp:scope}; details in Appendix~\ref{app:field}), and finally a third synthetic experiment, a registration-aware benchmark designed after the field tests had failed (Section~\ref{sec:exp:bench}). Before each main run, the protocol (grid, methods, iteration budgets, pass rules) was locked by a SHA-256 hash, and the scripts refuse to run if the hash does not match. The protocols of Experiments~1 and~2 were also committed and tagged in version control before their main runs. The protocol of Experiment~3 was committed while its main runs were in progress, and the field protocols only after their runs; for these the record of timing is the time stamp inside the lock file (Section~\ref{sec:exp:bench}, Appendix~\ref{app:field}). In Experiments~1 and~2, every design choice was made on two development realizations (900 and 901), and Experiment~3 added four (902--905); development realizations are never used for results. Test labels were never used to choose a shift, checkpoint or hyperparameter.
Every synthetic comparison is decided by the same pre-registered rule. A comparison \emph{improves} if the candidate's seismic-band RMSE is at most 0.90 times that of the best competitor, \emph{or} its band PCC is at least 0.05 higher. Here ``best'' means the competitor with the smallest mean band RMSE in that cell. A cell \emph{passes} if the comparison improves in at least 4 of 5 seeds (each averaged over realizations) and in more than half of the realizations (each averaged over seeds). All cells use eight test wells. Every synthetic comparison is decided by the same pre-registered rule. A comparison \emph{improves} if the candidate's seismic-band RMSE is at most 0.90 times that of the best competitor, \emph{or} its band PCC is at least 0.05 higher. Here ``best'' means the competitor with the smallest mean band RMSE in that cell. A cell \emph{passes} if the comparison improves in at least 4 of 5 seeds (each averaged over realizations) and in more than half of the realizations (each averaged over seeds). All cells use eight test wells.
@@ -128,7 +128,7 @@ Whether this gain exceeds what removing a population distortion could give depen
The registered structure is not the one expected for \mPM{}, whose labels sit at the posterior-mean warp. The natural idealization for the error of a posterior mean is the Berkson structure (b), and under (b) the bound is lower (Section~\ref{sec:theory:post}). The column $1/B_b$ gives this bound, computed post hoc in the same way but by sharpening the Oracle's predictions, at $\sigpost$ itself. The measured ratio is below it in 3 of the 8 wide cells, all at $c = 1$ (R0, R0h and R10tb). In R0h and R10tb the margin is less than 0.004, well inside the 95\% interval of the ratio. Sharpening also amplifies the Oracle's own estimation error, which lowers $1/B_b$, most of all at $c = 2$. Two variants limit this amplification. One holds the gain at its 60\,Hz value above 60\,Hz. The other replaces the spectrum of the Oracle's predictions by their cross-spectrum with the true labels. Both select the same three cells, and with the cross-spectrum the (a) bound is exceeded in only 5 of the 8 cells. The registered structure is not the one expected for \mPM{}, whose labels sit at the posterior-mean warp. The natural idealization for the error of a posterior mean is the Berkson structure (b), and under (b) the bound is lower (Section~\ref{sec:theory:post}). The column $1/B_b$ gives this bound, computed post hoc in the same way but by sharpening the Oracle's predictions, at $\sigpost$ itself. The measured ratio is below it in 3 of the 8 wide cells, all at $c = 1$ (R0, R0h and R10tb). In R0h and R10tb the margin is less than 0.004, well inside the 95\% interval of the ratio. Sharpening also amplifies the Oracle's own estimation error, which lowers $1/B_b$, most of all at $c = 2$. Two variants limit this amplification. One holds the gain at its 60\,Hz value above 60\,Hz. The other replaces the spectrum of the Oracle's predictions by their cross-spectrum with the true labels. Both select the same three cells, and with the cross-spectrum the (a) bound is exceeded in only 5 of the 8 cells.
Both bounds are evaluated at the posterior width, which understates the error of an overconfident posterior. Evaluated instead at the measured warp error of \mPM{} on the training wells, the ratio is still below the (a) bound in 6 of the 8 cells but below the (b) bound in at most one (R0, $c = 1$, under the two variants). An excess over the population bound is therefore not established. It appears under the classical structure, and under the Berkson structure it is confined to $c = 1$ and mostly disappears at the measured warp error. Whether the error of the mean warp has the Berkson structure was not tested (Section~\ref{sec:exp:mech}). Both bounds are evaluated at the posterior width, which understates the error of an overconfident posterior. Evaluated instead at the measured warp error of \mPM{} on the training wells, the ratio is still below the (a) bound in 6 of the 8 cells but below the (b) bound in at most one (R0, $c = 1$, under the two variants). An excess over the population bound is therefore not established. It appears under the classical structure, and under the Berkson structure it is confined to $c = 1$ and mostly disappears at the measured warp error. An exploratory test found the Berkson structure at $c = 1$ (Section~\ref{sec:exp:mech}).
The Oracle's advantage over \mPM{} can be compared with the same bounds. These ratios are post hoc and computed from the registered band RMSE of every method. At $c = 1$, $N = 16$, the Oracle's band RMSE was 0.93, 0.92 and 0.93 times that of \mPM{} at R0, R0h and Rm5, and 0.76 times at R10tb. These ratios are below the (a) bound in all four cells, below the (b) bound at $\sigpost$ in three or four of them, depending on the estimator, and below the (b) bound at the measured warp error in one or two. Part of the gap is not caused by registration at all. At $c = 0$, where the SMC warp RMSE on the training wells was 0.2--0.7\,ms and every bound is within 0.4\% of 1, the Oracle was still 1--3\% better than \mPM{} at $N = 16$. The two also differ in training length, which was selected on development data (500 and 250 iterations; Section~\ref{sec:method:train}). The Oracle's advantage over \mPM{} can be compared with the same bounds. These ratios are post hoc and computed from the registered band RMSE of every method. At $c = 1$, $N = 16$, the Oracle's band RMSE was 0.93, 0.92 and 0.93 times that of \mPM{} at R0, R0h and Rm5, and 0.76 times at R10tb. These ratios are below the (a) bound in all four cells, below the (b) bound at $\sigpost$ in three or four of them, depending on the estimator, and below the (b) bound at the measured warp error in one or two. Part of the gap is not caused by registration at all. At $c = 0$, where the SMC warp RMSE on the training wells was 0.2--0.7\,ms and every bound is within 0.4\% of 1, the Oracle was still 1--3\% better than \mPM{} at $N = 16$. The two also differ in training length, which was selected on development data (500 and 250 iterations; Section~\ref{sec:method:train}).
@@ -175,7 +175,7 @@ The SMC posterior was close to calibrated when the anchors were dense and $\sigm
\paragraph{Predictive uncertainty (descriptive).} \paragraph{Predictive uncertainty (descriptive).}
Every five-seed ensemble under-covered. At R10, $c = 1$, $N = 16$, the 90\% coverage was 0.79 for B5, 0.58 for \mPM-ens, 0.58 for \mRML-ens and 0.48 for Oracle-ens, with calibration errors 0.114, 0.300, 0.291 and 0.379. Ensembles trained on better labels predicted smaller $\sigma$ and covered less. Every five-seed ensemble under-covered. At R10, $c = 1$, $N = 16$, the 90\% coverage was 0.79 for B5, 0.58 for \mPM-ens, 0.58 for \mRML-ens and 0.48 for Oracle-ens, with calibration errors 0.114, 0.300, 0.291 and 0.379. Ensembles trained on better labels predicted smaller $\sigma$ and covered less.
Table~\ref{tab:t4} examines this pattern post hoc, with the dispersion ratio $\xi$ of Section~\ref{sec:theory:cov} computed from the saved test-well predictions. Every ensemble was too narrow: $\xi$ was 0.19 for the Oracle and at most 0.66 (B5), against 1 for a matched second moment. Because $\xi_O$ is small, Proposition~\ref{prop:coverage}(a) requires only a small excess of predicted variance for a method to cover more than the Oracle. Each method had a larger $\xi$ and a higher coverage than the Oracle in 80--99\% of the 240 realization cells. The ordering follows training length as much as label quality. At R10, B3c-R had a median warp error of 3.5\,ms on the training wells, against 0.55\,ms for the SMC mean warp. It was trained for the Oracle's 500 iterations and reached the same $\xi$ as \mPM{} at 250. Over all regimes its excess over the Oracle was the smallest of any method (0.02--0.03). Most of the excess of \mPM{} and \mRML{} was already present at $c = 0$, where the median warp error of their labels was 0.34\,ms. Within the 250-iteration group, the methods with worse labels (B3d, B3c) had the larger excess, as Proposition~\ref{prop:coverage}(b) predicts. Training length acts on its own. On the development realizations of Experiment~1 (SNR 10, $c = 1$, $N = 16$), the 90\% coverage of single Oracle models fell from 0.47 after 125 iterations to 0.23 after 500 and 0.10 after 2000. Their mean $\sigma$ fell by a factor of five, while their RMSE varied by less than 10\%. In Experiment~2 training length and label source are confounded, so parts (b) and (c) of Proposition~\ref{prop:coverage} are not tested. A seed ensemble of a heteroscedastic network does not carry the tie posterior to the test wells. We make no calibration claim. Table~\ref{tab:t4} examines this pattern post hoc, with the dispersion ratio $\xi$ of Section~\ref{sec:theory:cov} computed from the saved test-well predictions. Every ensemble was too narrow: $\xi$ was 0.19 for the Oracle and at most 0.66 (B5), against 1 for a matched second moment. Because $\xi_O$ is small, Proposition~\ref{prop:coverage}(a) requires only a small excess of predicted variance for a method to cover more than the Oracle. Each method had a larger $\xi$ and a higher coverage than the Oracle in 80--99\% of the 240 realization cells. The ordering follows training length as much as label quality. At R10, B3c-R had a median warp error of 3.5\,ms on the training wells, against 0.55\,ms for the SMC mean warp. It was trained for the Oracle's 500 iterations and reached the same $\xi$ as \mPM{} at 250. Over all regimes its excess over the Oracle was the smallest of any method (0.02--0.03). Most of the excess of \mPM{} and \mRML{} was already present at $c = 0$, where the median warp error of their labels was 0.34\,ms. Within the 250-iteration group, the methods with worse labels (B3d, B3c) had the larger excess. This is the direction that Proposition~\ref{prop:coverage}(b) gives for classical error, but B3d is a posterior mean, and the structure of these label errors was not tested. Training length acts on its own. On the development realizations of Experiment~1 (SNR 10, $c = 1$, $N = 16$), the 90\% coverage of single Oracle models fell from 0.47 after 125 iterations to 0.23 after 500 and 0.10 after 2000. Their mean $\sigma$ fell by a factor of five, while their RMSE varied by less than 10\%. In Experiment~2 training length and label source are confounded, so parts (b) and (c) of Proposition~\ref{prop:coverage} are not tested. A seed ensemble of a heteroscedastic network does not carry the tie posterior to the test wells. We make no calibration claim.
\begin{table}[t] \begin{table}[t]
\centering \centering
@@ -202,7 +202,175 @@ B5 & 125 & 1.10 & 1.36 & 0.662 & 0.79 & 0.199 & 0.199 & 0.179 \\
\subsection{Mechanism of the bank gain (exploratory)} \subsection{Mechanism of the bank gain (exploratory)}
\label{sec:exp:mech} \label{sec:exp:mech}
\todoblock{T2, exploratory, on the Experiment~2 bank (realizations 8--15), declared in \texttt{docs/research/t2-mechanism.md} before it is run (scheduled 1/11/2026). Planned tests: (i) warp error of the responsibility-weighted bank against that of the mean warp, at the end of training (re-registration, Remark~\ref{rem:lambda}); (ii) a control bank of random Gaussian-process time shifts with the same spread (label augmentation); (iii) split of the wide cells by posterior multimodality (Corollary~\ref{cor:twomode}); (iv) the Berkson-versus-classical covariance test of Section~\ref{sec:theory:post} for the bulk offset of \mPM{} and B3c-R, which decides which bound of Table~\ref{tab:h2b} applies; (v) \mPM{} retrained at the Oracle's budget, to separate training length from label error. The question is whether any gain remains beyond the population correction of the Berkson structure, not why a gain exceeds the registered bound. Disclose that the post hoc ratios and both bounds of Section~\ref{sec:exp:p2r}, at $\sigpost$ and at the warp error and with the 60\,Hz and cross-spectral variants, were inspected on 29/10/2026, before the declaration.} We examined five possible sources of the H2b gain on the Experiment~2 bank (realizations 8--15). The tests and their readings were declared in a file whose hash was recorded before any computation. The analysis is exploratory. It uses the test realizations, and the post hoc ratios and both bounds of Section~\ref{sec:exp:p2r} (at $\sigpost$ and at the warp error, with the 60\,Hz and cross-spectral variants) had been inspected before the declaration. Retraining for the analysis reproduced the registered runs exactly (10\,560 rows, maximum deviation 0). Unless stated otherwise, the cells are the eight wide cells at $N = 16$ (R0, R0h, R10tb and Rm5 at $c \in \{1, 2\}$).
\paragraph{(iv) The error of the mean warp is Berkson at $c = 1$.}
For the bulk offset of each training well, referred to the anchor tie, structure (b) predicts zero correlation between the error of \mPM{} and its estimate, and a negative correlation between the error and the true offset; structure (a) predicts the reverse (Section~\ref{sec:theory:post}). In all four wide cells at $c = 1$ the first correlation was near zero ($0.017$, $-0.035$, $-0.027$ and $-0.052$, each 95\% interval containing 0; pooled $-0.026$ $[-0.124, 0.072]$) and the second was $-0.44$ to $-0.77$. The estimated offsets were less dispersed than the true ones (variance ratio 0.41--0.81), as shrinkage of type (b) implies. At $c = 2$ neither structure fitted, and for B3c-R the anchor-referenced test is not clean, so we draw no structural conclusion for either. The bound that applies to \mPM{} at $c = 1$ is therefore $1/B_b$. Against it, the H2b ratio was lower only at R0 (0.967 against 0.982), R0h (0.970 against 0.972) and R10tb (0.890 against 0.893), two of these by at most 0.003, and in no cell at the measured warp error. A gain beyond the population correction of the Berkson structure is not established.
\paragraph{(v) A third of the Oracle gap is training length.}
\mPM{} was retrained at the Oracle's budget of 500 iterations. At $c = 1$ the Oracle's band RMSE was then 0.949, 0.944 and 0.957 times that of \mPM{} at R0, R0h and Rm5, against 0.927, 0.919 and 0.933 at the registered budgets. Training length thus accounts for 29--35\% of the registered gap, and the remaining 4--6\% is attributable to label error. At $c = 0$ the registered gap of 1--3\% nearly vanished (0.985--1.006). \mPM{} itself improved at 500 iterations in 7 of the 8 cells (ratios 0.973--0.985), so the budget selected on development data was not optimal for it in these cells. At equal budgets \mRML{} kept a gain over \mPM{}, smaller at R0 and R0h than at the registered budgets (0.980, 0.981, 0.887 and 0.986 at $c = 1$; 0.962, 0.913, 0.687 and 0.966 at $c = 2$, in the order R0, R0h, R10tb, Rm5).
\paragraph{(ii) A bank with the posterior's first two moments gets most of the gain at $c = 1$.}
A control bank, Ctl-GP, replaces the 64 SMC particles by 64 warps $\bar u + \eta$, where $\eta$ is Gaussian with the empirical covariance of the 1024 particles (Table~\ref{tab:methods}). Its members are as wide (marginal standard deviation 0.98--0.99 of the particles') and as wrong (warp error 1.00--1.03 times the SMC members') as the SMC bank, but no member is linked to the seismic. Ctl-GP improved on \mPM{} in 7 of the 8 cells. At $c = 1$ it matched \mRML{}: the ratios to \mPM{} were 0.970 and 0.970 (R0h), 0.904 and 0.890 (R10tb), 0.984 and 0.982 (Rm5), and 0.987 $[0.972, 1.003]$ and 0.967 (R0), for Ctl-GP and \mRML{}. At $c = 2$ the SMC bank was ahead at R0 (0.969 against 0.952), R0h (0.944 against 0.904) and R10tb (0.753 against 0.667), and not at Rm5. Under the declared reading, four cells were consistent with label augmentation alone, three showed information beyond the first two moments (all at $c = 2$), and one (R0, $c = 1$) was borderline; no reading had a majority.
\paragraph{(i) The responsibilities re-register the training labels.}
At the end of training, the responsibility-weighted warp $\sum_s \bar r_s T_s$ was closer to the true warp than the uniform mean of the bank in all 8 cells, with 13--40\% lower warp error (for example 1.86 to 1.38\,ms at R0, $c = 1$; 4.86 to 3.05\,ms at R10tb, $c = 1$; 19.3 to 11.7\,ms at R10tb, $c = 2$). The effective number of members was 3.5--28 of 64, so at $\lambda = 1/\tau_c$ RML is not near its $\lambda \to 0$ limit. The direction was the same at two other temperatures; we make no claim about the choice of $\lambda$. This is a property of the training wells: it is necessary for re-registration to help at test wells, not sufficient.
\paragraph{(iii) No evidence that multimodality drives the gain.}
We called a training well multimodal if a two-component Gaussian mixture fitted the window-mean offsets of its particles much better than one component ($\Delta\mathrm{BIC} > 10$, modes more than 4\,ms apart, smaller weight at least 0.1). Multimodal wells were rare except at R10tb, $c = 2$ (51\% of wells) and R0h, $c = 2$ (19\%). Within cells, the gain of \mRML{} over \mPM{} was not larger in realizations with at least a quarter of multimodal wells (adjusted difference of log ratios $-0.012$ $[-0.043, 0.020]$). With any multimodal well as the criterion the difference was $-0.017$ $[-0.031, -0.0002]$, a borderline result. The split has little power because multimodality is rare outside the unstable cells.
\paragraph{Reading.}
The five tests agree on the following. At $c = 1$, the label error of \mPM{} has the Berkson structure, and against the corresponding bound the bank gain does not exceed the population correction. A bank that carries only the width and correlation of the posterior obtains most of the gain at $c = 1$, which is what label augmentation predicts; information specific to the SMC bank mattered at $c = 2$, where the posterior is unstable and often multimodal. Re-registration of the training labels occurs, but it is not needed to explain the gain at $c = 1$. Label augmentation and re-registration are both finite-sample effects, consistent with the heuristic of Section~\ref{sec:theory:post} that with few wells finite-sample effects can outweigh the population bias. None of these results is confirmatory, and none identifies a mechanism. Experiment~3 carries the control bank and the equal-budget arm across its grid as disclosed additions (Section~\ref{sec:exp:bench}).
\subsection{Experiment 3: registration-aware benchmark}
\label{sec:exp:bench}
Experiment~3 asks how far the results of Experiment~2 extend and where they stop. It has five studies (Table~\ref{tab:benchdesign}), numbered as in the protocol; S5 and S6 are the exploratory analyses of Sections~\ref{sec:exp:mech} and~\ref{sec:exp:detect}, and S7 is the released task package. S1 fills the plane of drift factor and well count in every regime. S2 generates the data with a simulator that departs from the model used for registration (Section~\ref{sec:data:d2}). S3 adds the anchor-free alignment losses B4a--B4d to the competitors of Experiment~2. S4 repeats three cells with a second backbone, a TCN (Section~\ref{sec:method:train}). S8 replaces the estimated posterior by a label error of known two-mode structure, the setting of Corollary~\ref{cor:twomode}. At each training well the bank is the true warp and the true warp shifted by $s\Delta$, with $s = \pm 1$ drawn per well and $\Delta \in \{8, 16, 32\}$\,ms. PM2 trains on the label at the midpoint, so that its error is $\pm\Delta/2$; BK2 trains on the two-member bank with RML, and HM2 on the same bank with the hard minimum (Table~\ref{tab:methods}). Corollary~\ref{cor:twomode} predicts the transfer $\cos(\pi f\Delta)$ for PM2. The bank of BK2 contains the true warp, but it is the point label shifted by $\pm\Delta/2$ with equal weights, so in the limit $\lambda \to 0$ its transfer would be $\cos^2(\pi f\Delta)$ by the same corollary. A transfer near 1 requires the responsibilities to select the member that agrees with the seismic (Remark~\ref{rem:lambda}). The protocol calls BK2 calibrated; it is calibrated only in the weaker sense that the truth is a member, not in the sense of Proposition~\ref{prop:bank}.
\begin{table}[!htbp]
\centering
\caption{Design of Experiment~3. All studies use test realizations 8--15, five seeds and eight test wells per realization. Cells of S1 and S3 that coincide with Experiment~2 ($c \in \{0, 1, 2\}$, $N \in \{4, 16\}$) are read from Experiment~2. Iteration budgets are those of Experiment~2; Ctl-GP, PM2 and BK2 use 250, HM2 125, and every TCN method 125.}
\label{tab:benchdesign}
\small
\setlength{\tabcolsep}{3pt}
\begin{tabular}{lp{0.16\linewidth}p{0.27\linewidth}p{0.25\linewidth}p{0.13\linewidth}}
\toprule
Study & Question & Cells & Methods & Claims \\
\midrule
S1 & drift $\times$ wells & 5 regimes $\times$ $c \in \{0, 0.5, 1, 1.5, 2\}$ $\times$ $N \in \{2, 4, 8, 16\}$ & Oracle, B3b, B3c, B3c-R, B3d, \mPM, \mRML & S1-H1, S1-H2 \\
S2 & misspecification & R10, Rm5 $\times$ 7 presets $\times$ $c = 1$ $\times$ $N \in \{4, 16\}$ & as S1 without B3d, plus Ctl-GP & S2-H1 (3 axes), S2-H2 \\
S3 & anchor-free losses & 5 regimes $\times$ $c \in \{0, 1, 2\}$ $\times$ $N \in \{4, 16\}$ & B4a--B4d, Ctl-GP & S3-H1 \\
S4 & backbone & R10, Rm5, R0h $\times$ $c = 1$ $\times$ $N \in \{4, 16\}$ & as S2 without Ctl-GP, TCN & S4-H1, S4-H2 \\
S8 & two-mode error & R10, Rm5 $\times$ $c = 1$ $\times$ $N \in \{4, 16\}$ $\times$ $\Delta \in \{8, 16, 32\}$\,ms & Oracle, PM2, BK2, HM2 & S8-H1, S8-H2 \\
\bottomrule
\end{tabular}
\end{table}
\paragraph{Pre-registration and deviation.}
The protocol of Experiment~3 was locked before its main runs, with nine claims, a prediction for each, and the decision rules of Experiment~2. Comparisons with point ties use the cell rule of Experiment~2, and a claim on a regime passes as H2a does (both cells at $c = 1$ pass, with the zero-drift guard where the statement includes it). Comparisons between two label sources are decided by the rule \emph{better}: the candidate has the lower band RMSE in at least 4 of 5 seeds and in more than half of the realizations, with no margin. The nine claims yield eleven verdicts (S2-H1 gives one per axis), with no family-wise correction. The experiment was designed after Experiment~2, after the field tests and after the post hoc analyses of Section~\ref{sec:exp:p2r}, and it reuses the test realizations 8--15. Its protocol was committed to version control while the main runs were in progress; the record of timing is the time stamp inside the lock file, four minutes before the first main run. S1, S3 and S4 also reuse the SMC particles of Experiment~2, after a check that one cell (R10, realization 8, $c = 1$, $N = 4$) reproduces its particles and predictions bit for bit. Its claims are therefore extensions of Experiment~2 on the same realizations, not independent replications. The levels of S2 and the TCN budgets were chosen on four new development realizations (902--905). The rule for the TCN picked 125 iterations, the smallest candidate; the candidate set was not extended. Two arms motivated by the exploratory analysis of Section~\ref{sec:exp:mech}, which had already seen the test realizations, are disclosed additions that enter no rule: the control bank Ctl-GP in S2 and S3, and every method retrained at 500 iterations. S8-H2 was narrowed before the lock: on development data BK2 was worse than PM2 at $\Delta = 8$\,ms, and that clause became descriptive.
\paragraph{Two readings of the verdicts.}
After the runs, the locked code that extracts the verdicts was found to differ from the locked statements in three places (Table~\ref{tab:benchverdicts}). For S1-H1 it requires exactly two cells at R10, $c = 1.5$, but S1 has four values of $N$, so it returns no verdict. For S2-H1 it reports each axis but no overall verdict, which agrees with the statement (one verdict per axis). For S3-H1 it adds Ctl-GP to the competitors, whereas the statement names B3b, B3c, B3c-R and B4a--B4d. We did not edit the locked code. A separate script, outside the code hash, checks the lock and applies the statements as worded. We report both readings. They differ in conclusion only for S3-H1.
\begin{table}[!htbp]
\centering
\caption{Verdicts of Experiment~3. As worded: the locked statements applied by a separate script; as run: the output of the locked code. No family-wise correction.}
\label{tab:benchverdicts}
\small
\setlength{\tabcolsep}{3pt}
\begin{tabular}{lp{0.47\linewidth}lll}
\toprule
Claim & Statement (abridged) & Prediction & As worded & As run \\
\midrule
S1-H1 & H2a extends to R10, $c = 1.5$, $N \in \{4, 16\}$ & pass & pass & none$^a$ \\
S1-H2 & in wide families, the gain of \mRML{} over \mPM{} grows with $N$ & pass & pass & pass \\
S2-H1 & H2a at R10, $c = 1$ under the L1 level of & & & \\
\quad rock physics & \quad unit-dependent rock physics (rp\_L1) & pass & \textbf{fail} & fail \\
\quad wavelet & \quad frequency-dependent phase (wv\_L1) & pass & \textbf{fail} & fail \\
\quad drift & \quad warp-prior hyperparameters (dr\_L1) & uncertain & pass & pass \\
S2-H2 & \mRML/\mPM{} $\le 1.02$ for all 14 presets $\times$ regimes & pass & pass & pass \\
S3-H1 & H2a unchanged with B4a--B4d added to the competitors & pass & pass$^b$ & \textbf{fail}$^c$ \\
S4-H1 & H2a at R10, $c = 1$ with the TCN backbone & pass & pass & pass \\
S4-H2 & \mRML-TCN better than \mPM-TCN at Rm5 and R0h, $c = 1$, $N = 16$ & pass$^d$ & pass & pass \\
S8-H1 & transfer of PM2 negative in $(1/(2\Delta), 3/(2\Delta))$ at R10, $\Delta = 32$\,ms & pass & pass & pass \\
S8-H2 & BK2 better than PM2 at $\Delta \in \{16, 32\}$\,ms, $N = 16$, R10 and Rm5 & pass & pass & pass \\
\bottomrule
\end{tabular}
\smallskip
\footnotesize $^a$The code requires exactly two cells. $^b$Passes at R10, R0 and Rm5. $^c$Ctl-GP among the competitors. $^d$Recorded as uncertain: the TCN has no recurrent context.
\end{table}
\paragraph{S1: the gain of \mPM{} over point ties holds in most of the plane.}
S1-H1 passed. At R10, $c = 1.5$, \mPM{} reduced band RMSE relative to the best point tie (B3c-R) by 15\% at $N = 4$ (0.853 [0.805, 0.910], 5/5 seeds, 7/8 realizations) and by 20\% at $N = 16$ (0.796 [0.762, 0.826], 8/8). Across all 100 cells, \mPM{} was better than the best point tie in 91 (Fig.~\ref{fig:bench_s1}a). The ratio was 0.78--0.89 at R10 and 0.84--0.96 at R0 and Rm5. All nine exceptions are in the regimes with sparse anchors, seven at R10tb and two at R0h; four of them are at $N = 2$. The excess of \mPM{} over the Oracle grows with the posterior width: fitting $\mathrm{RMSE}^2_{\mPM} = \mathrm{RMSE}^2_{\mathrm{Oracle}} + \beta\,\sigpost^2$ per regime gives $\beta = 0.009$--$0.018$\,p.u.$^2$/ms$^2$, with $R^2 = 0.29$ (R10) to 0.61 (R0, R10tb). This is the second-order dependence of the finite-sample heuristic of Section~\ref{sec:theory:post}, but it explains only part of the variation.
S1-H2 passed. In every one of the 13 families (regime, $c$) whose $N = 16$ cell is wide, the ratio \mRML/\mPM{} was lower at $N = 16$ than at $N = 2$, and the pooled Spearman correlation between $\log_2 N$ and the ratio was $-0.47$ (one-sided permutation within families, $p < 10^{-4}$). Across the plane the ratio fell with $\sigpost$ (Spearman $\rho = -0.66$ over the 100 cells; Fig.~\ref{fig:bench_s1}b). \mRML{} was better than \mPM{} in 44 of the 52 wide cells; all eight exceptions are at $N \le 4$ and have ratios 0.994--1.008. Over the 48 narrow cells the mean ratio was 0.995. The largest gains were at R10tb, where only two anchors constrain each warp and $\sigpost$ reaches 12\,ms: 0.734 at $c = 1.5$ and 0.667 at $c = 2$ ($N = 16$).
\begin{figure}[!htbp]
\centering
\includegraphics[width=\linewidth]{bench_s1.pdf}
\caption{S1 phase diagrams over drift factor $c$ and number of training wells $N$, by regime. (a) Band RMSE of \mPM{} divided by that of the best point tie (B3b, B3c, B3c-R). (b) Band RMSE of \mRML{} divided by that of \mPM. Entries are means over 8 realizations $\times$ 5 seeds; values in parentheses fail the rule \emph{better}. Outlined cells in (b) are wide ($\sigpost \ge 1.5$\,ms). Cells at $c \in \{0, 1, 2\}$, $N \in \{4, 16\}$ are those of Experiment~2. Cells at $c = 2$ have an unstable posterior.}
\label{fig:bench_s1}
\end{figure}
\paragraph{S2: H2a does not survive rock-physics or wavelet-phase misspecification.}
S2-H1 failed for rock physics and for the wavelet, contrary to both predictions, and passed for drift (Table~\ref{tab:s2}). We therefore claim H2a under misspecification only for the warp-prior hyperparameters (dr\_L1), at R10. The two failures have different causes.
Under unit-dependent rock physics, the registration was nearly unaffected: the SMC warp error rose from 1.20 to 1.52\,ms at $N = 4$ and from 0.63 to 1.05\,ms at $N = 16$, with 90\% coverage 0.87. The learning problem became harder for every method. The Oracle's band RMSE rose by factors of 1.56 and 1.84, and at $N = 16$ \mPM{} stayed within 3\% of it. The ratio to the best point tie rose to 0.940 and 0.934, so the cells missed the 0.90 margin, and the band PCC difference ($+0.044$, $+0.041$) stayed below $+0.05$. \mPM{} was still better than the best point tie by the rule \emph{better} at both $N$. The difference between the squared band RMSE of the best point tie and that of \mPM{} fell only from 0.137 to 0.122\,p.u.$^2$ at $N = 4$ and from 0.132 to 0.107 at $N = 16$. When a shift between the simulator and the model raises the error of every method, a ratio rule dilutes a largely preserved label gain. This is a reading of a failed claim; it does not turn the verdict into a pass.
Under a frequency-dependent wavelet phase, the registration failed. The SMC re-estimated a constant phase of 43--46$^\circ$ and its posterior collapsed onto a wrong warp: warp error 2.58 and 2.26\,ms with 90\% coverage 0.17 and 0.10, 3.3--3.6 times its width. The band RMSE of \mPM{} rose by 25\% ($N = 4$) and 50\% ($N = 16$) relative to the nominal cells, while that of B3c, a correlation tie with the statistical wavelet, rose by at most 4\%, and B3c became the best point tie. At L2 the loss was larger (\mPM{} 1.22 and 1.39 times B3c). Under attenuation (wv\_Q) the posterior kept its coverage (0.86--0.87), and the cell passed at $N = 16$ only. Under the drift presets the coverage was 0.78--0.91 (dr\_L1) and 0.67--0.70 (dr\_L2), and the ratios stayed near their nominal values; at dr\_L2, $N = 4$, the cell failed on seeds (3/5) with a ratio of 0.892.
At Rm5 the protocol declared a null in advance: the noise is 1.78 times the signal and buries model errors of 0.22--0.34 of the noise. The registration diagnostics stayed near their nominal values (warp error 3.1--4.1\,ms against 3.31 and 2.91\,ms; coverage 0.74--0.88 against 0.83 and 0.86), except dr\_L1, whose warp error rose by up to 40\%. Of the 14 Rm5 cells, 13 passed the H2a cell rule.
S2-H2 passed: averaged over $N$, \mRML/\mPM{} was at most 1.02 for every preset and regime (0.984--1.020 at R10, 0.984--1.012 at Rm5). The bank did not harm, but in S2 it helped little. No R10 cell was wide, and \mRML{} was better than \mPM{} in 3 of the 14 R10 cells; at Rm5, where every cell was wide, it was better in 7 of 14 (ratios 0.970--1.020). \mRML/Ctl-GP was 0.985--1.009 in all 28 cells.
\begin{table}[!htbp]
\centering
\caption{S2 at R10, $c = 1$ (values for $N = 4$ / $N = 16$ where two are given). Presets are defined in Section~\ref{sec:data:d2}. Model error: RMS residual between the clean seismic and the best synthetic within the registration's model family at the true warp, relative to the noise RMS at R10; drift presets leave the seismic unchanged. Warp RMSE and cov$_{90}$: SMC posterior on the training wells. Ratio: band RMSE of \mPM{} divided by that of the best point tie; $^\ast$ cell passes the H2a rule. \mRML/\mPM: mean over $N$ (S2-H2). Oracle: band RMSE of the Oracle relative to the nominal cell, $N = 16$. Drift presets change the true warp, not the forward model.}
\label{tab:s2}
\small
\setlength{\tabcolsep}{4pt}
\begin{tabular}{lccccccc}
\toprule
& & & & \multicolumn{2}{c}{ratio} & & \\
\cmidrule(lr){5-6}
Preset & model error & warp RMSE (ms) & cov$_{90}$ & $N = 4$ & $N = 16$ & \mRML/\mPM & Oracle \\
\midrule
nominal & 0.23 & 1.20 / 0.63 & 0.85 / 0.89 & 0.857$^\ast$ & 0.782$^\ast$ & 1.000 & 1 \\
rp\_L1 & 1.24 & 1.52 / 1.05 & 0.87 / 0.87 & 0.940 & 0.934 & 0.999 & 1.84 \\
rp\_L2 & 1.68 & 2.15 / 1.52 & 0.83 / 0.86 & 0.963 & 0.955 & 0.998 & 2.13 \\
wv\_L1 & 1.08 & 2.58 / 2.26 & 0.17 / 0.10 & 1.023 & 1.042 & 1.020 & 1.00 \\
wv\_L2 & 1.93 & 4.74 / 4.24 & 0.04 / 0.03 & 1.217 & 1.386 & 1.003 & 1.02 \\
wv\_Q & 1.41 & 1.68 / 1.06 & 0.86 / 0.87 & 0.927 & 0.842$^\ast$ & 1.019 & 0.97 \\
dr\_L1 & -- & 1.63 / 1.25 & 0.78 / 0.91 & 0.862$^\ast$ & 0.798$^\ast$ & 0.984 & 1.00 \\
dr\_L2 & -- & 2.25 / 1.38 & 0.67 / 0.70 & 0.892 & 0.820$^\ast$ & 0.988 & 1.03 \\
\bottomrule
\end{tabular}
\end{table}
\paragraph{S3: anchor-free losses do not change H2a; the control bank does.}
As worded, S3-H1 passed at R10, R0 and Rm5, and failed at R0h and R10tb, where it is descriptive. B4a--B4d were never the best competitor at $c \le 1$, so the ratios equal those of Table~\ref{tab:h2a}. They stayed behind the point ties: at R10, $c = 1$, their band RMSE was 1.36, 1.31, 0.97 and 0.98 at $N = 4$ and 1.21, 1.14, 0.82 and 0.79 at $N = 16$, against 0.94 and 0.83 for B3b and 0.61 and 0.46 for \mPM. As run, with Ctl-GP among the competitors, S3-H1 failed in every regime. At $c = 1$ Ctl-GP was the best competitor in every regime, and the ratio of \mPM{} to it was 0.99--1.02 in R10, R0 and Rm5, so no cell passed. Ctl-GP is a bank built from the same posterior, not a point tie, and the statement did not name it. The reading as run nevertheless shows that the advantage of \mPM{} does not extend to a bank with the same first two moments.
Across the grid of S3, the control bank (T2-1) repeated the reading of Section~\ref{sec:exp:mech}. Ctl-GP was better than \mPM{} in 16 of the 30 cells by the rule \emph{better}, which has no margin; ratios below 0.975 occurred only at $c \ge 1$ in R0, R0h, R10tb and Rm5 (for example 0.954 and 0.904 at R10tb, $c = 1$), and at R10 the ratio was 0.98--1.01. \mRML{} was better than Ctl-GP at $c = 2$ in R0, R0h, R10tb (0.895 and 0.886) and, at $N = 16$, Rm5. At $c = 1$ the ratio was 0.975--1.001, and \mRML{} was better only at R0 and at R10tb with $N = 4$. Information in the SMC bank beyond its first two moments mattered where the posterior is unstable.
\paragraph{S4: the results hold with a second backbone.}
S4-H1 and S4-H2 passed. With the TCN at R10, $c = 1$, \mPM{} reduced band RMSE relative to the best TCN point tie (B3c-R) by 16\% and 18\% (0.840 [0.787, 0.904], $\Delta\mathrm{PCC} = +0.052$; 0.823 [0.802, 0.841]). \mRML{}-TCN was better than \mPM{}-TCN at R0h (0.977 [0.968, 0.987]) and Rm5 (0.983 [0.975, 0.991]) at $N = 16$. The TCN was a weaker backbone. Its band RMSE was 0--7\% above that of the CNN--GRU at $N = 4$ and at R0h and Rm5 with $N = 16$, and 14--24\% above at R10 with $N = 16$, where the three label sources became nearly equal (Oracle 0.560, \mPM{} 0.561, \mRML{} 0.565). Outside the claims, H2a with the TCN passed at Rm5 (0.914 and 0.913, on band PCC) and failed at R0h (0.944 and 0.943).
\paragraph{S8: a two-mode error reverses the band, and a bank that contains the truth repairs it.}
S8-H1 passed (Fig.~\ref{fig:bench_s8}). At R10, $\Delta = 32$\,ms, the measured transfer of PM2 relative to the Oracle, averaged over the usable frequencies in 15.6--46.9\,Hz, was $-0.70$ ($N = 4$) and $-0.49$ ($N = 16$), against $-0.69$ and $-0.49$ for $\cos(\pi f\Delta)$ over the same frequencies; its first zero crossing was at 14.6\,Hz against 15.6\,Hz in theory. At Rm5 the values were $-0.70$ and $-0.74$, against $-0.74$ and $-0.71$. S8-H2 passed in all four cells (Table~\ref{tab:s8}). At $N = 16$, BK2 reduced band RMSE relative to PM2 by 66\% and 72\% at R10 ($\Delta = 16$, 32\,ms) and by 29\% and 37\% at Rm5, and it came within 4\% of the Oracle. In the three cells at $N = 16$ with usable frequencies in the reversed band, its transfer there was 0.92--1.00, against means of 0.05--0.59 for $\cos^2(\pi f\Delta)$ at the same frequencies. BK2 thus did more than average its two members, as re-registration by the responsibilities would. HM2 was close to BK2, but its band RMSE was higher in every cell. At $\Delta = 8$\,ms, which is descriptive, BK2 was better than PM2 at $N = 16$ but not at $N = 4$.
\begin{table}[!htbp]
\centering
\caption{S8 (two-mode label error, $c = 1$): band RMSE ratios, mean over 8 realizations $\times$ 5 seeds, for $N = 4$ / $N = 16$. BK2/PM2 at $N = 16$ with 95\% CI; $^\ast$ BK2 better than PM2 at $N = 16$ (rule \emph{better}). $\Delta = 8$\,ms is descriptive.}
\label{tab:s8}
\small
\setlength{\tabcolsep}{4pt}
\begin{tabular}{lcccccc}
\toprule
Regime & $\Delta$ (ms) & PM2/Oracle & BK2/PM2 & BK2/PM2, $N = 16$ & HM2/PM2 & BK2/Oracle \\
\midrule
R10 & 8 & 1.56 / 1.78 & 0.88 / 0.60 & 0.600 [0.569, 0.635]$^\ast$ & 0.90 / 0.67 & 1.37 / 1.07 \\
R10 & 16 & 2.30 / 2.94 & 0.49 / 0.34 & 0.340 [0.327, 0.360]$^\ast$ & 0.54 / 0.37 & 1.13 / 1.00 \\
R10 & 32 & 2.73 / 3.64 & 0.43 / 0.28 & 0.280 [0.267, 0.294]$^\ast$ & 0.46 / 0.31 & 1.17 / 1.02 \\
Rm5 & 8 & 1.16 / 1.17 & 0.98 / 0.88 & 0.881 [0.852, 0.912]$^\ast$ & 1.01 / 0.92 & 1.14 / 1.03 \\
Rm5 & 16 & 1.37 / 1.46 & 0.83 / 0.71 & 0.706 [0.680, 0.734]$^\ast$ & 0.85 / 0.73 & 1.14 / 1.03 \\
Rm5 & 32 & 1.46 / 1.64 & 0.80 / 0.64 & 0.635 [0.609, 0.673]$^\ast$ & 0.82 / 0.66 & 1.16 / 1.04 \\
\bottomrule
\end{tabular}
\end{table}
\begin{figure}[!htbp]
\centering
\includegraphics[width=\linewidth]{bench_s8.pdf}
\caption{S8 at $N = 16$: measured transfer $\hat H(f)$ of PM2 (labels at the midpoint of two modes $\Delta$ apart), BK2 (two-member bank containing the true warp, RML) and HM2 (same bank, hard minimum) relative to the Oracle, pooled over test wells, realizations and seeds, for (a) R10 and (b) Rm5. Curves are shown at the usable frequencies (Oracle cross-spectrum at least 10\% of its maximum above 6\,Hz). Dashed: $\cos(\pi f\Delta)$ (Corollary~\ref{cor:twomode}). Shaded: the band $1/(2\Delta) < f < 3/(2\Delta)$ in which the transfer of the midpoint label is negative.}
\label{fig:bench_s8}
\end{figure}
\paragraph{Equal training budgets (disclosed).}
We retrained every method for 500 iterations; no rule uses this arm. No result above changed direction. At R10, $c = 1.5$, \mPM/best point tie was 0.867 and 0.793. At R10, $c = 1$, it was 0.944 and 0.920 under rp\_L1 and 1.020 and 1.042 under wv\_L1, so the S2 failures are not caused by the training length. With the TCN at R10 it was 0.864 and 0.813. The bank gain changed in narrow cells: at R10, $c = 1.5$, \mRML/\mPM{} was 0.997 and 0.999, against 0.978 and 0.987 at the registered budgets. In wide cells it remained (R10tb, $c = 1.5$: 0.916 and 0.747). BK2/PM2 in S8 was unchanged within 0.01.
\paragraph{Reading.}
At R10 the benchmark extends H2a to $c = 1.5$, to a second backbone and to a misspecified warp prior, and it locates two failures. Labels at the posterior-mean warp lose their advantage over point ties when the wavelet phase is outside the registration's model, because the posterior then collapses onto a wrong warp. Under unit-dependent rock physics their absolute gain is nearly kept, but it no longer meets the margin of the rule. The bank gain over \mPM{} grows with the number of wells and with the posterior width, and in no preset did the bank harm. With a label error of known two-mode structure, the prediction of Corollary~\ref{cor:twomode} for the midpoint label holds: it reverses the sign of the learned response in the predicted band. A two-member bank that contains the truth removes the reversal, and with 16 wells it does more than averaging could, consistent with re-registration by the responsibilities. All of this is one simulator family with F3 statistics, on eight test realizations that Experiment~2 had already used.
\subsection{Detectability of a gain at blind wells (exploratory)} \subsection{Detectability of a gain at blind wells (exploratory)}
\label{sec:exp:detect} \label{sec:exp:detect}
@@ -213,7 +381,7 @@ A field test scores predictions at blind wells against labels that need a tie of
We used the cells at R10, R0 and Rm5 with $c = 1$ and $N \in \{4, 16\}$, and compared \mRML{} with the best point tie of each cell, the competitor of H2a: B3c-R in four cells, B3c at R10 with $N = 4$ and B3b at Rm5 with $N = 4$. For each test well, the reference is the true label read at $t + s(t)$, with $s = a + bx$, where $x$ runs linearly from $-1$ to 1 across the window, $a \sim \N(0, \sigma_{\mathrm{ref}}^2)$ and $b \sim \N(0, \sigma_{\mathrm{ref}}^2/4)$. The RMS of $s$ is then $1.04\,\sigma_{\mathrm{ref}}$. Each well receives 64 draws. A well counts as a win if the seed-averaged \mRML{} has the lower band RMSE against this reference. Wells of one realization share their training wells, so their outcomes are correlated. The probability that a rule passes with $n$ blind wells is therefore computed from a beta-binomial distribution whose mean is the win rate and whose intra-class correlation is that of the outcome within realizations. We compare two rules: $k$ of $n$ wells with $k = \lceil 0.75n\rceil$, the form of both field gates (three of four on F3, five of six on Volve), and a one-sided sign test at $\alpha = 0.05$. $N^\star$ is the smallest $n \le 40$ at which a rule passes with probability at least 0.8. We used the cells at R10, R0 and Rm5 with $c = 1$ and $N \in \{4, 16\}$, and compared \mRML{} with the best point tie of each cell, the competitor of H2a: B3c-R in four cells, B3c at R10 with $N = 4$ and B3b at Rm5 with $N = 4$. For each test well, the reference is the true label read at $t + s(t)$, with $s = a + bx$, where $x$ runs linearly from $-1$ to 1 across the window, $a \sim \N(0, \sigma_{\mathrm{ref}}^2)$ and $b \sim \N(0, \sigma_{\mathrm{ref}}^2/4)$. The RMS of $s$ is then $1.04\,\sigma_{\mathrm{ref}}$. Each well receives 64 draws. A well counts as a win if the seed-averaged \mRML{} has the lower band RMSE against this reference. Wells of one realization share their training wells, so their outcomes are correlated. The probability that a rule passes with $n$ blind wells is therefore computed from a beta-binomial distribution whose mean is the win rate and whose intra-class correlation is that of the outcome within realizations. We compare two rules: $k$ of $n$ wells with $k = \lceil 0.75n\rceil$, the form of both field gates (three of four on F3, five of six on Volve), and a one-sided sign test at $\alpha = 0.05$. $N^\star$ is the smallest $n \le 40$ at which a rule passes with probability at least 0.8.
\paragraph{A reference error of a few milliseconds reverses the ranking.} \paragraph{A reference error of a few milliseconds reverses the ranking.}
With an exact reference, \mRML{} won at 81--97\% of the test wells, and its median band RMSE was 0.80--0.92 times that of the competitor (Table~\ref{tab:t3}). Both numbers worsened as the reference error grew. At $\sigma_{\mathrm{ref}} = 4$\,ms, the win rate was 0.46--0.64 and the median ratio 0.96--1.01. At 8\,ms, the win rate was 0.22--0.44 and the median ratio exceeded 1 in every cell: against this reference the point tie scored better, although against the true labels it was worse. In the three cells with $N = 16$, the median ratio crossed 1 between 3.6 and 4.3\,ms. Corollary~\ref{cor:tolerance} places the crossing, to leading order and without shrinkage, at $\sigma/\sqrt2$, where $\sigma$ is the tie error of the point label. The RMS warp error of B3c-R on the training wells of these cells was 4.2, 5.8 and 7.3\,ms at R10, R0 and Rm5, so $\sigma/\sqrt2$ is 3.0, 4.1 and 5.1\,ms. The simulated crossings follow the same order and lie within 1\,ms of these values. The agreement can only be approximate: \mRML{} is not the oracle that the corollary assumes, the tie errors are not constant Gaussian shifts, and the reference error here includes a stretch. With an exact reference, \mRML{} won at 81--97\% of the test wells, and its median band RMSE was 0.80--0.92 times that of the competitor (Table~\ref{tab:t3}). Both numbers worsened as the reference error grew. At $\sigma_{\mathrm{ref}} = 4$\,ms, the win rate was 0.46--0.64 and the median ratio 0.96--1.01. At 8\,ms, the win rate was 0.22--0.44 and the median ratio exceeded 1 in every cell: against this reference the point tie scored better, although against the true labels it was worse. In the three cells with $N = 16$, the median ratio crossed 1 between 3.6 and 4.3\,ms. Without shrinkage, Corollary~\ref{cor:tolerance} places the crossing below $\sigma/\sqrt2$, and at $\sigma/\sqrt2$ to leading order, where $\sigma$ is the tie error of the point label. The RMS warp error of B3c-R on the training wells of these cells was 4.2, 5.8 and 7.3\,ms at R10, R0 and Rm5, so $\sigma/\sqrt2$ is 3.0, 4.1 and 5.1\,ms. The simulated crossings, 3.6, 3.8 and 4.3\,ms by linear interpolation, follow the same order and lie within 1\,ms of these values: below them at R0 and Rm5, and 0.6\,ms above at R10, which shrinkage allows. The agreement can only be approximate: \mRML{} is not the oracle that the corollary assumes, the tie errors are not constant Gaussian shifts, and the reference error here includes a stretch.
\paragraph{Wells needed.} \paragraph{Wells needed.}
With an exact reference, the sign test needs five blind wells at R0 (both $N$) and at R10 with $N = 16$, and 18 and 11 wells at Rm5 with $N = 4$ and 16. At R10 with $N = 4$, the outcomes are strongly correlated within realizations (intra-class correlation 0.45), and no $n \le 40$ reaches a pass probability of 0.8. The number of wells rises quickly with the reference error. At 1\,ms, four of the six cells need 11--30 wells; at 2\,ms, only R0 stays within 40 (23 and 37 wells); at 3\,ms or more, no cell does. The $k$-of-$n$ rule appears to need fewer wells, but it is not a test. With independent wells and no true difference, it passes with probability $5/16 = 0.31$ at $n = 4$ and $7/64 = 0.11$ at $n = 6$. A one-sided sign test at $\alpha = 0.05$ cannot reject at all with four wells, because its smallest attainable $p$-value is $1/16$. With an exact reference, the sign test needs five blind wells at R0 (both $N$) and at R10 with $N = 16$, and 18 and 11 wells at Rm5 with $N = 4$ and 16. At R10 with $N = 4$, the outcomes are strongly correlated within realizations (intra-class correlation 0.45), and no $n \le 40$ reaches a pass probability of 0.8. The number of wells rises quickly with the reference error. At 1\,ms, four of the six cells need 11--30 wells; at 2\,ms, only R0 stays within 40 (23 and 37 wells); at 3\,ms or more, no cell does. The $k$-of-$n$ rule appears to need fewer wells, but it is not a test. With independent wells and no true difference, it passes with probability $5/16 = 0.31$ at $n = 4$ and $7/64 = 0.11$ at $n = 6$. A one-sided sign test at $\alpha = 0.05$ cannot reject at all with four wells, because its smallest attainable $p$-value is $1/16$.

View File

@@ -4,15 +4,18 @@
\paragraph{What the synthetic experiments show.} \paragraph{What the synthetic experiments show.}
The two experiments separate two questions that are easy to conflate. The first is whether the tie posterior is informative. The second is whether training on it helps. In Experiment~1 the posterior was not informative: 64 anchor-conditioned samples reweighted by tie likelihoods stayed as wide as the anchors allowed, and labels drawn from them were no better than a good correlation-based point tie. Once the posterior contracted (SMC, Experiment~2), labels at its mean beat every point tie in all three full-anchor regimes, and a bank of its samples gained further when the posterior was wide. Better registration of the training labels came first. Marginalizing over what remained then added a smaller, width-dependent gain. Neither result says that marginalization rescues a poor posterior, and Experiment~1 is direct evidence that it does not. The two experiments separate two questions that are easy to conflate. The first is whether the tie posterior is informative. The second is whether training on it helps. In Experiment~1 the posterior was not informative: 64 anchor-conditioned samples reweighted by tie likelihoods stayed as wide as the anchors allowed, and labels drawn from them were no better than a good correlation-based point tie. Once the posterior contracted (SMC, Experiment~2), labels at its mean beat every point tie in all three full-anchor regimes, and a bank of its samples gained further when the posterior was wide. Better registration of the training labels came first. Marginalizing over what remained then added a smaller, width-dependent gain. Neither result says that marginalization rescues a poor posterior, and Experiment~1 is direct evidence that it does not.
\paragraph{Where the posterior-mean advantage stops.}
Experiment~3 extends the advantage of \mPM{} at R10 to $c = 1.5$, to a second backbone and to a misspecified warp prior, but the misspecification study S2 shows that it depends on the registration's model. Under a frequency-dependent wavelet phase, which a constant-phase fit cannot represent, the SMC posterior concentrated on a wrong warp (90\% coverage 0.10--0.17), and its mean became a worse label than a correlation tie that uses the statistical wavelet. A posterior that is confidently wrong is worse than a cruder point tie. Under unit-dependent rock physics, registration was nearly unaffected, and the gain of \mPM{} in squared band RMSE was largely preserved, but every method became worse and the ratio missed the registered margin. The two failures call for different checks before the posterior is used on field data: the first for the phase behaviour of the wavelet over the target window, the second for the size of the label gain relative to the error of the best predictor. Averaged over the two well counts, the bank was never more than 2\% worse than \mPM{} in any preset (S2-H2).
\paragraph{Where the bank gain comes from.} \paragraph{Where the bank gain comes from.}
The theory gives a population limit, and whether the measured gains exceed it depends on the structure of the tie error. In population, a calibrated bank has the minimizer of training on the true labels (Proposition~\ref{prop:bank}), and no method improves on a point label by more than the factor $\rho^\star$ of \eqref{eq:rhostar}. Its distortion term is of fourth order in the tie error. For the Oracle predictions of Experiment~2 it sits near 70\,Hz, where a Berkson error distorts much more than a classical error of the same width (Section~\ref{sec:theory:post}). Under the registered bound for classical error, \mRML{} gained more than the limit allows in 7 of the 8 wide cells at $N = 16$. Under the bound for Berkson error, the natural idealization for labels at the posterior-mean warp, it did so in 3 cells at the posterior width and in at most 1 at the measured warp error of \mPM{} (Section~\ref{sec:exp:p2r}). In most cells the bank gain is therefore no larger than removing a population sharpening of \mPM{} could give, but this rests on an error structure that was not tested. On synthetic data the covariance test of Section~\ref{sec:theory:post} can settle it (Section~\ref{sec:exp:mech}). The theory gives a population limit, and whether the measured gains exceed it depends on the structure of the tie error. In population, a calibrated bank has the minimizer of training on the true labels (Proposition~\ref{prop:bank}), and no method improves on a point label by more than the factor $\rho^\star$ of \eqref{eq:rhostar}. Its distortion term is of fourth order in the tie error. For the Oracle predictions of Experiment~2 it sits near 70\,Hz, where a Berkson error distorts much more than a classical error of the same width (Section~\ref{sec:theory:post}). Under the registered bound for classical error, \mRML{} gained more than the limit allows in 7 of the 8 wide cells at $N = 16$. Under the bound for Berkson error, the natural idealization for labels at the posterior-mean warp, it did so in 3 cells at the posterior width and in at most 1 at the measured warp error of \mPM{} (Section~\ref{sec:exp:p2r}). An exploratory covariance test (Section~\ref{sec:exp:mech}) found the Berkson structure at $c = 1$, and neither structure at $c = 2$. At $c = 1$, the bank gain is therefore no larger than removing a population sharpening of \mPM{} could give, except by margins of at most 0.015.
Finite-sample effects can add to this population effect or outweigh it: the label error itself is of first order, and its effect on the conditional variance that a network must absorb is of second order, against the fourth-order population distortion (Section~\ref{sec:theory:post}). Part of the gap to the Oracle is not caused by registration at all. At $c = 0$, with SMC warp errors of 0.2--0.7\,ms, the Oracle was still 1--3\% better than \mPM{}, and it was trained twice as long. \mRML{} closed 27--46\% of the gap between \mPM{} and the Oracle at $c = 1$, and it did not reach the Oracle in any wide cell at $N = 16$. Finite-sample effects can add to this population effect or outweigh it: the label error itself is of first order, and its effect on the conditional variance that a network must absorb is of second order, against the fourth-order population distortion (Section~\ref{sec:theory:post}). Part of the gap to the Oracle is not caused by registration at all. At $c = 0$, with SMC warp errors of 0.2--0.7\,ms, the Oracle was still 1--3\% better than \mPM{}, and it was trained twice as long. Retrained at the Oracle's budget, \mPM{} closed 29--35\% of that gap at $c = 1$ (Section~\ref{sec:exp:mech}). \mRML{} closed 27--46\% of the gap between \mPM{} and the Oracle at $c = 1$, and it did not reach the Oracle in any wide cell at $N = 16$.
Beyond the population correction, three mechanisms could contribute to the bank gain. The bank acts as label augmentation, and the learned variance absorbs its spread. For $\lambda > 0$ the responsibilities re-register the labels during training (Remark~\ref{rem:lambda}). A multimodal posterior gives the mean warp a non-Gaussian error, against which a bank can gain more than the Gaussian bound allows (Corollary~\ref{cor:twomode}). Until the exploratory analysis of Section~\ref{sec:exp:mech} is done, the bank gain is an empirical regularity of this benchmark whose source is not identified. Beyond the population correction, three finite-sample mechanisms could contribute to the bank gain: label augmentation, with the learned variance absorbing the spread of the bank; re-registration of the labels by the responsibilities for $\lambda > 0$ (Remark~\ref{rem:lambda}); and a multimodal posterior, whose mean warp has a non-Gaussian error (Corollary~\ref{cor:twomode}). The exploratory analyses bear on each but identify none. A Gaussian bank with only the first two moments of the posterior obtained most of the gain at $c = 1$, as label augmentation predicts, and across the grid of Experiment~3 information specific to the SMC bank mattered mainly at $c = 2$ (Sections~\ref{sec:exp:mech} and~\ref{sec:exp:bench}). The responsibilities did re-register the training labels, and with the two-mode error of S8 a bank containing the true warp did more than averaging its members could. No evidence linked the gain to multimodality of the SMC posterior. The bank gain therefore remains an empirical regularity of this benchmark whose source is not identified.
\paragraph{When to use a bank rather than the posterior mean.} \paragraph{When to use a bank rather than the posterior mean.}
Within this benchmark the answer depends on the posterior width. When the posterior is narrow ($\sigpost < 1.5$\,ms), \mRML{} and \mPM{} are equivalent within 1\% on average, so the bank costs little and brings nothing. When the posterior is wide, because of low SNR, sparse anchors or strong drift, \mRML{} passed in all eight wide cells at $N = 16$, and over all cells at $N = 16$ the gain grew with the width (Spearman $\rho = -0.85$). The bank adds little to training once the posterior has been computed: the network is evaluated once per window, and only the likelihood is evaluated for each of the 64 labels. A practical rule for this benchmark is therefore to train with the bank whenever the tie posterior is wider than about 1.5\,ms. The largest gain at $c = 1$ came with sparse anchors (R10tb), where the posterior was overconfident and the bank was narrower than the error it was meant to represent, so in that regime the bank helped without being calibrated. On real data the width cannot be checked against a true warp, and it depends on $\sigma_a$. Within this benchmark the answer depends on the posterior width. When the posterior is narrow ($\sigpost < 1.5$\,ms), \mRML{} and \mPM{} are equivalent within 1\% on average, so the bank costs little and brings nothing. When the posterior is wide, because of low SNR, sparse anchors or strong drift, \mRML{} passed in all eight wide cells at $N = 16$, and over all cells at $N = 16$ the gain grew with the width (Spearman $\rho = -0.85$). The bank adds little to training once the posterior has been computed: the network is evaluated once per window, and only the likelihood is evaluated for each of the 64 labels. Experiment~3 confirms this over the full plane of drift and well count: \mRML{} was better than \mPM{} in 44 of the 52 wide cells, the eight exceptions being at $N \le 4$ and within 1\%, and in all 13 wide families its gain was larger with 16 wells than with 2. A practical rule for this benchmark is therefore to train with the bank whenever the tie posterior is wider than about 1.5\,ms. A Gaussian bank with the posterior's mean and covariance is a cheaper alternative that came within 2.5\% of the SMC bank at $c = 1$. The largest gain at $c = 1$ came with sparse anchors (R10tb), where the posterior was overconfident and the bank was narrower than the error it was meant to represent, so in that regime the bank helped without being calibrated. On real data the width cannot be checked against a true warp, and it depends on $\sigma_a$.
\paragraph{The anchor uncertainty is the main risk.} \paragraph{The anchor uncertainty is the main risk.}
Every positive result of Experiment~2 assumes that $\sigma_a$ is known. Halving or doubling it removed the H2a advantage in every cell and miscalibrated the posterior in both directions (Table~\ref{tab:sigmaa}). On F3 the time--depth markers are horizon-tie picks on the same seismic. A type-II estimate treats them as exact (0.4\,ms), while the spread between markers and horizons suggests 7\,ms. The two values place F3 at opposite ends of the $\sigpost$ axis, at about 0.6\,ms (narrow, like R10) or 2.5--3.4\,ms (wide, close to Rm5), and the arms at 3.5 and 14\,ms did not change the F3 outcome (Appendix~\ref{sec:exp:f3}). The width that decides between \mPM{} and \mRML{} inherits this dependence. An estimate of $\sigma_a$ from independent time--depth data at wells outside the test set is therefore a precondition for using the tie posterior, not a refinement of it. Every positive result of Experiment~2 assumes that $\sigma_a$ is known. Halving or doubling it removed the H2a advantage in every cell and miscalibrated the posterior in both directions (Table~\ref{tab:sigmaa}). On F3 the time--depth markers are horizon-tie picks on the same seismic. A type-II estimate treats them as exact (0.4\,ms), while the spread between markers and horizons suggests 7\,ms. The two values place F3 at opposite ends of the $\sigpost$ axis, at about 0.6\,ms (narrow, like R10) or 2.5--3.4\,ms (wide, close to Rm5), and the arms at 3.5 and 14\,ms did not change the F3 outcome (Appendix~\ref{sec:exp:f3}). The width that decides between \mPM{} and \mRML{} inherits this dependence. An estimate of $\sigma_a$ from independent time--depth data at wells outside the test set is therefore a precondition for using the tie posterior, not a refinement of it.
@@ -25,13 +28,14 @@ Both field gates failed, but in neither case was the timing of the training labe
\paragraph{Limitations.} \paragraph{Limitations.}
\begin{itemize} \begin{itemize}
\item \textbf{One simulator.} Every confirmatory result comes from one generator, whose statistics and warp prior were estimated on F3. The registration methods use the warp family and the wavelet of the generator. They differ from it only in the prior hyperparameters, which are fitted to the training anchors or fixed, and in the estimated wavelet phase, so a misspecified warp family or wavelet has not been tested. \todo{S2 of \texttt{protocol\_bench} (three misspecification axes). If S2 is not locked and run before submission, call the study a controlled synthetic study, not a benchmark, throughout.} \item \textbf{One simulator.} Every confirmatory result comes from one generator family, whose statistics and warp prior were estimated on F3. Experiment~3 departs from the registration's model along three axes, at two levels each; H2a held only under the misspecified warp prior, and the levels are not calibrated to any field. Lateral heterogeneity, multiples, anisotropy and non-stationary noise were not simulated.
\item \textbf{Experiment~3 is not an independent replication.} It was designed after the field tests and the post hoc analyses, and it reuses the test realizations and SMC particles of Experiment~2 (Section~\ref{sec:exp:bench}). Its locked verdict code differed from the locked statements in three places, and we report both readings; they differ in conclusion only for S3-H1.
\item \textbf{Experiment~2 is a deviation.} It was pre-registered and run on new realizations, but it was designed after Experiment~1 had failed, and re-running was not among the options registered for that failure (Section~\ref{sec:exp:diag}). \item \textbf{Experiment~2 is a deviation.} It was pre-registered and run on new realizations, but it was designed after Experiment~1 had failed, and re-running was not among the options registered for that failure (Section~\ref{sec:exp:diag}).
\item \textbf{Strong drift.} At $c = 2$ the SMC posterior was multimodal and its mean was unstable between runs. These cells are reported but are not evidence. \item \textbf{Strong drift.} At $c = 2$ the SMC posterior was multimodal and its mean was unstable between runs. These cells are reported but are not evidence.
\item \textbf{Untested stresses.} The bulk-offset prior $\sigma_b$ was not varied, and the anchor-free losses B4a--B4d were not rerun with the SMC posterior. \todo{S3 (B4 under the SMC posterior) and S8 (controlled cycle-skip regime).} \item \textbf{Untested stresses.} Experiment~3 did not vary the anchor uncertainty, varied the bulk-offset prior only together with the other drift hyperparameters (dr\_L1), and tested cycle skipping only in the idealized form of S8, a constant two-mode error built from the true warp.
\item \textbf{Monte Carlo variability.} At low SNR the SMC run-to-run stability criterion failed in one of four development cells at $c = 1$, mainly through the phase estimate. This variability is small relative to $\sigpost$, but it was not removed. \item \textbf{Monte Carlo variability.} At low SNR the SMC run-to-run stability criterion failed in one of four development cells at $c = 1$, mainly through the phase estimate. This variability is small relative to $\sigpost$, but it was not removed.
\item \textbf{Uncertainty quantification.} Seed ensembles under-covered for every method ($\xi$ of 0.19--0.66 at R10, $c = 1$, $N = 16$), and more so for better labels and longer training. Because training length and label source are confounded, parts (b) and (c) of Proposition~\ref{prop:coverage} remain untested. On F3 the macro 80\% coverage of every probabilistic method was 0.38--0.52, and on Volve 0.29--0.39. Carrying the tie posterior to predictive uncertainty at a new well needs a different mechanism, for example prediction in depth through the warp posterior. We did not attempt this. \item \textbf{Uncertainty quantification.} Seed ensembles under-covered for every method ($\xi$ of 0.19--0.66 at R10, $c = 1$, $N = 16$), and more so for better labels and longer training. Because training length and label source are confounded, parts (b) and (c) of Proposition~\ref{prop:coverage} remain untested. On F3 the macro 80\% coverage of every probabilistic method was 0.38--0.52, and on Volve 0.29--0.39. Carrying the tie posterior to predictive uncertainty at a new well needs a different mechanism, for example prediction in depth through the warp posterior. We did not attempt this.
\item \textbf{The tempering $\lambda$.} $\lambda = 1/\tau_c$ is a heuristic fixed in advance. We did not compare it with alternatives and make no claim about it. \item \textbf{The tempering $\lambda$.} $\lambda = 1/\tau_c$ is a heuristic fixed in advance. We did not compare it with alternatives and make no claim about it.
\item \textbf{One backbone.} All learned methods share one CNN--GRU; only two F3 ablations used a second, purely convolutional backbone (Table~\ref{tab:f3abl}). Assumption (B) of Proposition~\ref{prop:ident} holds only approximately for it. \todo{S4 (second backbone).} \item \textbf{Two backbones.} Apart from two F3 ablations (Table~\ref{tab:f3abl}), the only second backbone is the TCN of study S4, in three cells. Both claims held with it, but it was weaker and selected the smallest budget, so this is a check of robustness, not evidence of independence from the architecture. Assumption (B) of Proposition~\ref{prop:ident} holds only approximately for either backbone.
\item \textbf{Detectability.} Section~\ref{sec:exp:detect} rescored predictions with the skill of Experiment~2 against references whose errors are smooth and independent of the predictions. Its numbers of wells hold for predictors of comparable skill. A reference tied on the same seismic adds a covariance with the predictions that we did not model. \item \textbf{Detectability.} Section~\ref{sec:exp:detect} rescored predictions with the skill of Experiment~2 against references whose errors are smooth and independent of the predictions. Its numbers of wells hold for predictors of comparable skill. A reference tied on the same seismic adds a covariance with the predictions that we did not model.
\end{itemize} \end{itemize}

View File

@@ -3,12 +3,12 @@
A well tie is an uncertain estimate, yet learning workflows treat it as exact. Its error is an error in the time index of the label. Under an independence assumption, the error convolves the optimal predictor with its distribution and blurs the seismic band, and without time anchors the absolute timing of a network and its label alignment is not identified. An estimated tie can have the classical error structure, which blurs the learned predictor, or the Berkson structure, which sharpens it. A calibrated bank of posterior labels removes both biases in population, but its population gain over a point label is of fourth order in the tie error. A well tie is an uncertain estimate, yet learning workflows treat it as exact. Its error is an error in the time index of the label. Under an independence assumption, the error convolves the optimal predictor with its distribution and blurs the seismic band, and without time anchors the absolute timing of a network and its label alignment is not identified. An estimated tie can have the classical error structure, which blurs the learned predictor, or the Berkson structure, which sharpens it. A calibrated bank of posterior labels removes both biases in population, but its population gain over a point label is of fourth order in the tie error.
On a registration-aware synthetic benchmark calibrated to F3, the first pre-registered comparison failed because the anchor-only posterior was not informative. In the second, designed after that failure, labels at the mean of a sequential Monte Carlo tie posterior beat the best point tie by 8--22\% in seismic-band RMSE, mostly already without drift, provided that the anchor uncertainty was correctly specified. Training on the posterior bank gained further when the posterior was wide. Under the Berkson error structure that is natural for a posterior-mean tie, the gain stayed within the population limit in most cells. That structure was not tested, and the experiments do not separate the population effect from finite-sample effects of the bank. On a registration-aware synthetic benchmark calibrated to F3, the first pre-registered comparison failed because the anchor-only posterior was not informative. In the second, designed after that failure, labels at the mean of a sequential Monte Carlo tie posterior beat the best point tie by 8--22\% in seismic-band RMSE, mostly already without drift, provided that the anchor uncertainty was correctly specified. Training on the posterior bank gained further when the posterior was wide. Under the Berkson error structure that is natural for a posterior-mean tie, the gain stayed within the population limit in most cells. An exploratory test found that structure at F3-like drift, where a Gaussian bank with the first two moments of the posterior obtained most of the gain. A third experiment, designed after the field tests and run on the same test realizations, located the limits of these results. The posterior-mean advantage held at stronger drift, with a second backbone and under a misspecified warp prior. It did not hold under a frequency-dependent wavelet phase, which made the tie posterior overconfident, nor, by the registered margin, under unit-dependent rock physics. With a two-mode label error, midpoint labels reversed the sign of the learned seismic band as predicted, and a bank containing the true warp removed the reversal.
Whether such gains hold on field data is a question that the public datasets we examined cannot answer. A blind-well comparison of tie methods needs a reference that is independent of the seismic and accurate to about 1\,ms, enough blind wells for a test with adequate power, an anchor uncertainty estimated outside the test set, and networks with skill in the seismic band. The F3 and Volve tests met none of these conditions and failed, and Teapot Dome has independent time--depth references at no more than two of its 152 wells. We claim no improvement on field data and no calibrated uncertainty. The benchmark, the locked protocols and the detectability analysis are the means to test such claims once a dataset that meets these conditions is available. Whether such gains hold on field data is a question that the public datasets we examined cannot answer. A blind-well comparison of tie methods needs a reference that is independent of the seismic and accurate to about 1\,ms, enough blind wells for a test with adequate power, an anchor uncertainty estimated outside the test set, and networks with skill in the seismic band. The F3 and Volve tests met none of these conditions and failed, and Teapot Dome has independent time--depth references at no more than two of its 152 wells. We claim no improvement on field data and no calibrated uncertainty. The benchmark, the locked protocols and the detectability analysis are the means to test such claims once a dataset that meets these conditions is available.
\paragraph{Data and code availability.} \paragraph{Data and code availability.}
The F3 Netherlands data are publicly available from dGB Earth Sciences under a CC BY-SA 3.0 licence. The Volve data are available from Equinor under a CC BY-NC-SA 4.0 licence. The Teapot Dome data (RMOTC, U.S.\ Department of Energy) are available from the Texas Data Repository \citep{bader2017teapot}. \todo{Verify the three licences on the providers' pages at submission (Teapot: recorded as CC0 in the project notes).} The code, locked protocols, synthetic generator configurations and the scripts that produce every table and figure are available at \todo{repository URL and archived DOI}. The F3 Demo 2023 data are available from dGB Earth Sciences through the TerraNubis portal under a CC BY-SA 3.0 licence \citep{dgb2023f3demo}. The Volve data are available from Equinor \citep{equinor2018volve}; the licence files of the release name CC BY-NC-SA 4.0, and the data owners are Equinor, ExxonMobil, Bayerngas and the Norwegian Petroleum Directorate. The Teapot Dome data (RMOTC, U.S.\ Department of Energy) are available from the Texas Data Repository \citep{bader2017teapot}. \todo{Verify the Teapot licence on the repository page at submission (recorded as CC0 in the project notes). F3 and Volve were checked on the providers' pages on 2 November 2026.} The code, locked protocols, synthetic generator configurations and the scripts that produce every table and figure are available at \todo{repository URL and archived DOI}. The derived data from which every table and figure is computed (summaries, run-level metrics, saved test predictions and the descriptive F3 porosity volume) are archived with a manifest of SHA-256 hashes at \todo{archive DOI}, in separate archives for the F3-derived and synthetic data (CC BY-SA 3.0) and for the Volve-derived data (CC BY-NC-SA 4.0). A clean-room check recomputes the summaries, verdicts, post hoc tables and figures from the code and these archives alone, without raw seismic data. The benchmark package contains 630 tasks on the test realizations 8--15 and the development realizations 900--905, each with its inputs and its hidden true warps and labels, together with the reference results of 21 methods and a scorer that applies the locked rules; it is archived at \todo{Zenodo DOI; licence inherited from F3 (CC BY-SA 3.0), to be confirmed}.
\paragraph{Computer code availability.} \paragraph{Computer code availability.}
\todo{Required by Computers \& Geosciences. Fields in the journal's template (unverified against the current guide): name of the code; developers and contact (e-mail, phone); year first available; hardware requirements (development on an NVIDIA RTX 3060 12\,GB and an H200); software required (Python 3.12, PyTorch; give the versions of the environment locks); program language; program size; licence; repository link.} \todo{Required by Computers \& Geosciences. Fields in the journal's template (unverified against the current guide): name of the code; developers and contact (e-mail, phone); year first available; hardware requirements (development on an NVIDIA RTX 3060 12\,GB and an H200); software required (Python 3.12, PyTorch; give the versions of the environment locks); program language; program size; licence; repository link.}
@@ -23,4 +23,4 @@ The F3 Netherlands data are publicly available from dGB Earth Sciences under a C
\todo{Elsevier requires authors to disclose the use of generative AI in preparing the manuscript. The authors must write this statement.} \todo{Elsevier requires authors to disclose the use of generative AI in preparing the manuscript. The authors must write this statement.}
\paragraph{Acknowledgements.} \paragraph{Acknowledgements.}
\todo{Acknowledgements and funding.} We thank dGB Earth Sciences for making the F3 data available as an OpendTect project via their TerraNubis portal (terranubis.com), and Equinor and the former Volve licence partners (ExxonMobil and Bayerngas) and the Norwegian Petroleum Directorate for releasing the Volve data. \todo{Other acknowledgements and funding.}

View File

@@ -25,7 +25,7 @@ Moments are averaged over $t$ in the window, and $h$ ranges over functions of $X
For $a > 0$, $h^\star$ has the same PCC and band PCC as $\hat y^\star$, and its in-band spectrum is $a^2|P|^2 S_m$. The statement holds at the population level for a sufficiently rich model class. For $a > 0$, $h^\star$ has the same PCC and band PCC as $\hat y^\star$, and its in-band spectrum is $a^2|P|^2 S_m$. The statement holds at the population level for a sufficiently rich model class.
\subsection{Proposition~\ref{prop:ident}} \subsection{Proposition~\ref{prop:ident}}
Since $t_{u + \beta e_b}(z) = t_u(z) + \beta$, we have $z_{u+\beta e_b}(t) = z_u(t - \beta)$ and hence $y^{u + \beta e_b} = T_\beta y^u$. By (B), $\mu_{\theta'} = T_\beta\mu_\theta$ and $\sigma_{\theta'} = T_\beta\sigma_\theta$. The Gaussian log-likelihood on a window $I$ is $\sum_{i\in I}\log\N(y(t_i - \beta); \mu(t_i-\beta), \sigma^2(t_i-\beta))$, which is the log-likelihood on the window $I - \beta$. Summed over windows that tile the trace, the two objectives differ only at edge samples. The log-sum-exp of RML preserves this invariance, because every bank member is shifted by the same amount. The prior on $g$ is unchanged, because $g$ is unchanged. This proves (a). Parts (b) and (c) follow by direct computation from $t_{u+\beta e_b}(z_{wk}) = t_{u_w}(z_{wk}) + \beta$. The prior adds $-\sum_w (b_w + \beta)^2/(2\sigma_b^2)$, with curvature $N/\sigma_b^2$. The anchors add $-\sum_{w,k}(t_{wk} - t_{u_w}(z_{wk}) - \beta)^2/(2\sigma_a^2)$, with curvature $\sum_w K_w/\sigma_a^2$. The expression for $\sd(\beta)$ is the inverse square root of the total curvature, that is, a quadratic approximation along the ridge. \hfill$\square$ Since $t_{u + \beta e_b}(z) = t_u(z) + \beta$, we have $z_{u+\beta e_b}(t) = z_u(t - \beta)$ and hence $y^{u + \beta e_b} = T_\beta y^u$. By (B), $\mu_{\theta'} = T_\beta\mu_\theta$ and $\sigma_{\theta'} = T_\beta\sigma_\theta$. The Gaussian log-likelihood on a window $I$ is $\sum_{i\in I}\log\N(y(t_i - \beta); \mu(t_i-\beta), \sigma^2(t_i-\beta))$, which is the log-likelihood on the window $I - \beta$. Summed over windows that tile the trace, the two objectives differ only at edge samples. The log-sum-exp of RML preserves this invariance, because every bank member is shifted by the same amount. The prior on $g$ is unchanged, because $g$ is unchanged. This proves (a). Parts (b) and (c) follow by direct computation from $t_{u+\beta e_b}(z_{wk}) = t_{u_w}(z_{wk}) + \beta$. The prior adds $-\sum_w (b_w + \beta)^2/(2\sigma_b^2)$, with curvature $N/\sigma_b^2$. The anchors add $-\sum_{w,k}(t_{wk} - t_{u_w}(z_{wk}) - \beta)^2/(2\sigma_a^2)$, with curvature $\sum_w K_w/\sigma_a^2$. The expression for $\sd(\beta)$ is the inverse square root of the total curvature, that is, a quadratic approximation along the ridge with the other parameters fixed. In a Gaussian approximation this conditional variance is at most the marginal variance of $\beta$, by the law of total variance. \hfill$\square$
\subsection{Proposition~\ref{prop:tie}} \subsection{Proposition~\ref{prop:tie}}
(a) Conditional on $X$ and $\delta(t) = d$, independence gives $\E[y(t+d)\mid X, \delta(t) = d] = m(t+d)$ and $\E[y(t+d)^2\mid X, \delta(t) = d] = \E[y(t+d)^2\mid X]$. Integrating over $p_t(\cdot\mid X)$ (Fubini, using (A2)) gives $\tilde m(t)$ and $\E[\tilde y(t)^2\mid X] = \int p_t(d\mid X)\{\Var(y(t+d)\mid X) + m(t+d)^2\}\dd d$. Subtracting $\tilde m(t)^2$ gives the variance. (a) Conditional on $X$ and $\delta(t) = d$, independence gives $\E[y(t+d)\mid X, \delta(t) = d] = m(t+d)$ and $\E[y(t+d)^2\mid X, \delta(t) = d] = \E[y(t+d)^2\mid X]$. Integrating over $p_t(\cdot\mid X)$ (Fubini, using (A2)) gives $\tilde m(t)$ and $\E[\tilde y(t)^2\mid X] = \int p_t(d\mid X)\{\Var(y(t+d)\mid X) + m(t+d)^2\}\dd d$. Subtracting $\tilde m(t)^2$ gives the variance.
@@ -39,10 +39,10 @@ If $p_t = p(\cdot\mid X)$ does not depend on $t$, the window average of $\int p(
(b) Take $G(u, D) = \ell\big(y^u; \mu_\theta(X), \sigma_\theta(X)\big)$, a function of $(u, D)$ because $X$ is a function of $D$. Calibration gives $\sum_s \pi_s\ell_s = \E[\ell^\star\mid D]$, and taking expectations gives the claim. By Lemma~\ref{lem:sandwich}, $\RML_\lambda \to -\frac1n\sum_s\pi_s\ell_s$ as $\lambda \to 0$, so for every $\theta$ the limit has the expectation of the Gaussian negative log-likelihood on the true labels. Over functions of $X$, the latter is minimized sample by sample at $\mu_i = \E[y(t_i)\mid X]$ and $\sigma_i^2 = \Var(y(t_i)\mid X)$. For the MSE, $\E[\bar y - m\mid X] = 0$ by (a), so $\E(h - \bar y)^2 = \E(h - m)^2 + \E(m - \bar y)^2$ for every function $h$ of $X$. (b) Take $G(u, D) = \ell\big(y^u; \mu_\theta(X), \sigma_\theta(X)\big)$, a function of $(u, D)$ because $X$ is a function of $D$. Calibration gives $\sum_s \pi_s\ell_s = \E[\ell^\star\mid D]$, and taking expectations gives the claim. By Lemma~\ref{lem:sandwich}, $\RML_\lambda \to -\frac1n\sum_s\pi_s\ell_s$ as $\lambda \to 0$, so for every $\theta$ the limit has the expectation of the Gaussian negative log-likelihood on the true labels. Over functions of $X$, the latter is minimized sample by sample at $\mu_i = \E[y(t_i)\mid X]$ and $\sigma_i^2 = \Var(y(t_i)\mid X)$. For the MSE, $\E[\bar y - m\mid X] = 0$ by (a), so $\E(h - \bar y)^2 = \E(h - m)^2 + \E(m - \bar y)^2$ for every function $h$ of $X$.
The expansion of $\bar y - y^{\bar u}$ in Section~\ref{sec:theory:post} is Taylor's theorem in $u$; the first-order term vanishes because $\sum_s \pi_s (u_s - \bar u) = 0$. \hfill$\square$ The expansion of $\bar y - y^{\bar u}$ in Section~\ref{sec:theory:post} is a second-order Taylor expansion in $u$, formal because $u$ contains the drift function $g$; the first-order term vanishes because $\sum_s \pi_s (u_s - \bar u) = 0$. \hfill$\square$
\subsection{Corollary~\ref{cor:twomode}} \subsection{Corollary~\ref{cor:twomode}}
The characteristic function of $\pm\Delta/2$ with equal probabilities is $\frac12\big(e^{i\pi f\Delta} + e^{-i\pi f\Delta}\big) = \cos(\pi f\Delta)$, which is negative for $\pi/2 < \pi|f|\Delta < 3\pi/2$. Under (a) the transfer from $m$ to $\tilde m$ is $P$; under (b) it is $1/Q$, which has the sign of $Q$. A zero-mean Gaussian with variance $\Delta^2/4$ has characteristic function $e^{-2\pi^2(\Delta^2/4)f^2}$. The calibrated bank is covered by Proposition~\ref{prop:bank}(a). For the shifted bank, $\bar y(t) = \frac12\big[\tilde y(t + \Delta/2) + \tilde y(t - \Delta/2)\big]$, so $\E[\bar y\mid X]$ is $\tilde m$ filtered by $\cos(\pi f\Delta)$, that is, $m$ filtered by $\cos^2(\pi f\Delta)$. \hfill$\square$ The characteristic function of $\pm\Delta/2$ with equal probabilities is $\frac12\big(e^{i\pi f\Delta} + e^{-i\pi f\Delta}\big) = \cos(\pi f\Delta)$, which is negative for $\pi/2 < \pi|f|\Delta < 3\pi/2$. Under (a) the transfer from $m$ to $\tilde m$ is $P$. Under (b), $\hat m = Q\,\hat{\tilde m}$, so the transfer is $1/Q$ wherever $Q \ne 0$ and has the sign of $Q$; $Q$ has no zero inside the band, and at its zeros the identity forces $\hat m = 0$. A zero-mean Gaussian with variance $\Delta^2/4$ has characteristic function $e^{-2\pi^2(\Delta^2/4)f^2}$. The calibrated bank is covered by Proposition~\ref{prop:bank}(a). For the shifted bank, $\bar y(t) = \frac12\big[\tilde y(t + \Delta/2) + \tilde y(t - \Delta/2)\big]$, so $\E[\bar y\mid X]$ is $\tilde m$ filtered by $\cos(\pi f\Delta)$, that is, $m$ filtered by $\cos^2(\pi f\Delta)$. This is the population minimizer of MSE on $\bar y$ and, as in the proof of Proposition~\ref{prop:bank}(b), of the $\lambda \to 0$ limit of RML on the bank, because the bank average of the Gaussian negative log-likelihood is minimized in $\mu$ at $\bar y$. A calibrated bank would have transfer 1 by Proposition~\ref{prop:bank}(a), so this bank is not calibrated. \hfill$\square$
\subsection{Remark~\ref{rem:lambda} and Equation~\texorpdfstring{\eqref{eq:rhostar}}{(\ref{eq:rhostar})}} \subsection{Remark~\ref{rem:lambda} and Equation~\texorpdfstring{\eqref{eq:rhostar}}{(\ref{eq:rhostar})}}
For a finite bank, $\log\E_\pi e^{\lambda\ell} = \lambda\E_\pi\ell + \frac{\lambda^2}{2}\Var_\pi\ell + O(\lambda^3)$; dividing by $-\lambda n$ gives the expansion in Remark~\ref{rem:lambda}. For a finite bank, $\log\E_\pi e^{\lambda\ell} = \lambda\E_\pi\ell + \frac{\lambda^2}{2}\Var_\pi\ell + O(\lambda^3)$; dividing by $-\lambda n$ gives the expansion in Remark~\ref{rem:lambda}.
@@ -54,7 +54,7 @@ $B$ is linear, so $B(h - y) = B(h - m) + B(m - y)$. Here $B(h - m)$ is a functio
(b) Let $V = \E\Var(y\mid X)$. For the oracle, $v_O = w_O = V$. By (A1) and stationarity, $\E\tilde y^2 = \E y^2 = V + \E m^2$, so $v_j = \E\tilde y^2 - \E\tilde m^2 = V + \int(1 - P^2)S_m\dd f$. By the orthogonality used for \eqref{eq:rhostar}, without the band operator, $w_j = V + \E(\tilde m - m)^2 = V + \int(1 - P)^2S_m\dd f$. Hence $\Delta v - \Delta w = \int[(1 - P^2) - (1 - P)^2]S_m\dd f = 2\int P(1 - P)S_m\dd f$, and (a) with $\xi_O = 1$ gives the result. (b) Let $V = \E\Var(y\mid X)$. For the oracle, $v_O = w_O = V$. By (A1) and stationarity, $\E\tilde y^2 = \E y^2 = V + \E m^2$, so $v_j = \E\tilde y^2 - \E\tilde m^2 = V + \int(1 - P^2)S_m\dd f$. By the orthogonality used for \eqref{eq:rhostar}, without the band operator, $w_j = V + \E(\tilde m - m)^2 = V + \int(1 - P)^2S_m\dd f$. Hence $\Delta v - \Delta w = \int[(1 - P^2) - (1 - P)^2]S_m\dd f = 2\int P(1 - P)S_m\dd f$, and (a) with $\xi_O = 1$ gives the result.
(c) By orthogonality, $w_j = V + \E(\tilde m - m)^2 \ge V$. By Proposition~\ref{prop:tie}(b), $\Var(y(t)\mid X) \ge \int q(e\mid X)\Var(\tilde y(t+e)\mid X)\dd e$. Averaging over the window and taking expectations as in the proof of Proposition~\ref{prop:tie}, $V \ge \E\Var(\tilde y\mid X) = v_j$, so $\xi_j \le 1$. A calibrated bank has the population optimum of the oracle (Proposition~\ref{prop:bank}), so $\xi = 1$. (c) By orthogonality, $w_j = V + \E(\tilde m - m)^2 \ge V$. By Proposition~\ref{prop:tie}(b), $\Var(y(t)\mid X) \ge \int q(e\mid X)\Var(\tilde y(t+e)\mid X)\dd e$. Averaging over the window and taking expectations as in the proof of Proposition~\ref{prop:tie}, $V \ge \E\Var(\tilde y\mid X) = v_j$, so $\xi_j \le 1$. At $\lambda \to 0$, a calibrated bank has the population optimum of the oracle (Proposition~\ref{prop:bank}), so $\xi = \xi_O = 1$.
For the coverage statement, $\Pr(|y - \mu| \le zs) = \Pr(|Z| \le z\sqrt\xi) = 2\Phi(z\sqrt\xi) - 1$. \hfill$\square$ For the coverage statement, $\Pr(|y - \mu| \le zs) = \Pr(|Z| \le z\sqrt\xi) = 2\Phi(z\sqrt\xi) - 1$. \hfill$\square$
@@ -66,7 +66,7 @@ Because $B$ is linear and time-invariant and $\varepsilon_r$ is constant over th
Expanding both squares, the two MSEs differ only in the cross term, $-2\int S_{\hat y y}Q_r\dd f$ against $-2\int S_{\hat y y}\dd f$ over $|f| \ge f_c$. The difference is real, so it equals its real part. \hfill$\square$ Expanding both squares, the two MSEs differ only in the cross term, $-2\int S_{\hat y y}Q_r\dd f$ against $-2\int S_{\hat y y}\dd f$ over $|f| \ge f_c$. The difference is real, so it equals its real part. \hfill$\square$
\subsection{Corollary~\ref{cor:tolerance}} \subsection{Corollary~\ref{cor:tolerance}}
The expression for $G_r - G$ is \eqref{eq:refbias} applied to both methods. As in the proof of Corollary~\ref{cor:band}, $S_{my} = S_m$, so $S_{\hat y_A y} = HS_m$ and $S_{\hat y_B y} = HPS_m$. For $\hat y = Lm$ with a real filter $L$, $\E|B(\hat y - y)|^2 = \int_{|f|\ge f_c}(L^2 - 2L)S_m\dd f + \E|By|^2$. The difference between $L = HP$ and $L = H$ is $G$, and adding $G_r - G = -2\int_{|f|\ge f_c} H(1 - P)(1 - Q_r)S_m\dd f$ gives $G_r$. Both factors of the integrand of $G$ are non-negative when $0 \le H, P \le 1$. For Gaussian errors, $P = 1 - 2\pi^2\sigma^2f^2 + O(f^4)$ and $Q_r = 1 - 2\pi^2\sigma_r^2f^2 + O(f^4)$. The over-sharp case follows by substituting $S_{\hat y_B y} = HKS_m$. \hfill$\square$ The expression for $G_r - G$ is \eqref{eq:refbias} applied to both methods. As in the proof of Corollary~\ref{cor:band}, $S_{my} = S_m$, so $S_{\hat y_1 y} = HS_m$ and $S_{\hat y_2 y} = HPS_m$. For $\hat y = Lm$ with a real filter $L$, $\E|B(\hat y - y)|^2 = \int_{|f|\ge f_c}(L^2 - 2L)S_m\dd f + \E|By|^2$. The difference between $L = HP$ and $L = H$ is $G$, and adding $G_r - G = -2\int_{|f|\ge f_c} H(1 - P)(1 - Q_r)S_m\dd f$ gives $G_r$. Both factors of the integrand of $G$ are non-negative when $0 \le H, P \le 1$. For Gaussian errors, $P = e^{-2\pi^2\sigma^2f^2} = 1 - 2\pi^2\sigma^2f^2 + O(f^4)$ and $Q_r = e^{-2\pi^2\sigma_r^2f^2} = 1 - 2\pi^2\sigma_r^2f^2 + O(f^4)$, which gives the leading-order term. If $\sigma_r \ge \sigma/\sqrt2$, then $Q_r \le e^{-\pi^2\sigma^2f^2}$ and $2Q_r - 1 - P \le 2e^{-\pi^2\sigma^2f^2} - 1 - e^{-2\pi^2\sigma^2f^2} = -\big(1 - e^{-\pi^2\sigma^2f^2}\big)^2 \le 0$ at every $f$, so $G_r \le 0$ for $H = 1$. At $\sigma_r = \sigma/\sqrt2$ the inequality is strict wherever $S_m > 0$ in the band, so by continuity $G_r < 0$ also for $\sigma_r$ slightly below $\sigma/\sqrt2$. The over-sharp case follows by substituting $S_{\hat y_2 y} = HKS_m$. \hfill$\square$
\subsection{Lemmas~\ref{lem:s1}--\ref{lem:sdtw}} \subsection{Lemmas~\ref{lem:s1}--\ref{lem:sdtw}}
@@ -89,4 +89,4 @@ Substituting $\ell_A = -\frac12\langle A,D\rangle_w$, $\pi_A = |\mathcal P|^{-1}
\begin{equation*} \begin{equation*}
\RML_{2/\gamma} = -\frac{\gamma}{2n}\log\sum_{A}|\mathcal P|^{-1}e^{-\langle A,D\rangle_w/\gamma} = \frac{\mathrm{sDTW}_\gamma(D)}{2n} + \frac{\gamma}{2n}\log|\mathcal P| . \RML_{2/\gamma} = -\frac{\gamma}{2n}\log\sum_{A}|\mathcal P|^{-1}e^{-\langle A,D\rangle_w/\gamma} = \frac{\mathrm{sDTW}_\gamma(D)}{2n} + \frac{\gamma}{2n}\log|\mathcal P| .
\end{equation*} \end{equation*}
With symmetric steps, every path has total weight $2n$, and on the diagonal path $\langle A, D\rangle_w = 2\sum_i D_{ii}$, so $\ell_A = \sum_i\log\N(y_i;\mu_i,\sigma_i^2)$. \hfill$\square$ With symmetric steps and the start cell counted twice, every path has total weight $2 + (2n - 2) = 2n$, because the weight of each step equals its increment of $i + j$, which grows from $0$ to $2n - 2$ along the path; and on the diagonal path $\langle A, D\rangle_w = 2\sum_i D_{ii}$, so $\ell_A = \sum_i\log\N(y_i;\mu_i,\sigma_i^2)$. \hfill$\square$

View File

@@ -1,4 +1,4 @@
# Tài liệu không có toàn văn trong refs/ (cập nhật 26/10/2026) # Tài liệu không có toàn văn trong refs/ (cập nhật 02/11/2026)
Quy ước (28/10/2026): mỗi PDF trong `refs/` được đặt tên theo key BibTeX của nó trong `paper/refs.bib`, ví dụ `refs/buland2003bayesianwavelet.pdf`. Quy ước (28/10/2026): mỗi PDF trong `refs/` được đặt tên theo key BibTeX của nó trong `paper/refs.bib`, ví dụ `refs/buland2003bayesianwavelet.pdf`.
@@ -6,12 +6,11 @@ P03 (Xu et al. 2024) đã được tải tay ngày 26/10/2026. Các bài open ac
## Bỏ qua (không tải được, quyết định không theo đuổi) ## Bỏ qua (không tải được, quyết định không theo đuổi)
Ngày 28/10/2026 đã xác nhận lần cuối là không lấy được toàn văn của P04, P05, P07, P09. Bản thảo trích các bài này dựa trên abstract và có chú thích "assessed from the abstract only" (xem `docs/plan.md` mục 2.2). P03 không thuộc nhóm này: toàn văn nằm ở `refs/xu2024sts.pdf`. Ngày 28/10/2026 đã xác nhận lần cuối là không lấy được toàn văn của P04, P05, P07, P09. Ngày 02/11/2026 người dùng tải tay được P05 (`li2024bpinn.pdf`), nên P05 đã ra khỏi bảng dưới. Bản thảo trích các bài này dựa trên abstract và có chú thích "assessed from the abstract only" (xem `docs/plan.md` mục 2.2). P03 không thuộc nhóm này: toàn văn nằm ở `refs/xu2024sts.pdf`.
| Mã | Bài | DOI | | Mã | Bài | DOI |
| --- | --- | --- | | --- | --- | --- |
| P04 | Chen et al. 2024, IEEE TGRS | 10.1109/TGRS.2024.3460184 | | P04 | Chen et al. 2024, IEEE TGRS | 10.1109/TGRS.2024.3460184 |
| P05 | Li, Grana & Liu 2024, Geophysics | 10.1190/geo2023-0737.1 |
| P07 | Di & Abubakar 2023, Geophys. Prospect. | 10.1111/1365-2478.13333 | | P07 | Di & Abubakar 2023, Geophys. Prospect. | 10.1111/1365-2478.13333 |
| P09 | Dou & Li 2024, Comput. Geotech. | 10.1016/j.compgeo.2024.106194 | | P09 | Dou & Li 2024, Comput. Geotech. | 10.1016/j.compgeo.2024.106194 |
| — | White & Simm 2003, First Break 21(10) | 10.3997/1365-2397.21.10.25640 | | — | White & Simm 2003, First Break 21(10) | 10.3997/1365-2397.21.10.25640 |
@@ -19,7 +18,13 @@ Ngày 28/10/2026 đã xác nhận lần cuối là không lấy được toàn v
## Chỉ có abstract: quét SEG/EAGE ngày 28/10/2026 ## Chỉ có abstract: quét SEG/EAGE ngày 28/10/2026
Không có PDF vì EarthDoc và SEG Library chặn tải tự động. Abstract lấy từ OpenAlex; trích trong bài với chú thích "assessed from the abstract only". Key BibTeX: `lim2025awsm`, `lim2025bootnet`, `quesada2024faultlabels` (chưa có DOI), `huff2024anglestack`, `thiebaud2024lfc`, `rizzuti2024waveletflows`, `cordoba2025porosity`, `mirza2025labelquality`, `rizzuti2025uhr`, `guillon2020gtmetrics`. Nếu tải tay được bài nào, đặt tên PDF theo key. Nên ưu tiên `lim2025awsm`. Không có PDF vì EarthDoc và SEG Library chặn tải tự động. Abstract lấy từ OpenAlex; trích trong bài với chú thích "assessed from the abstract only". Key BibTeX còn lại: `quesada2024faultlabels` (chưa có DOI), `huff2024anglestack`, `thiebaud2024lfc`, `cordoba2025porosity`, `mirza2025labelquality`. Nếu tải tay được bài nào, đặt tên PDF theo key.
**02/11/2026:** đã có toàn văn `rizzuti2024waveletflows.pdf` (5 trang, sha256 3e69efdb…) và `rizzuti2025uhr.pdf` (5 trang, sha256 42756aca…), bản do Shearwater Geoservices đăng công khai. Toàn văn khớp với cách Bảng `tab:positioning` xếp hai bài (DL ✓, không có tie hay bất định tie). Bài 2025 tự ghi việc đưa well log CPT và hiệu ứng wavelet vào khung UQ là việc sẽ làm. Chú thích ᵃ trong bảng lúc đó chưa bỏ (đã bỏ sau đó, xem đoạn dưới). Cùng ngày, OpenAlex, Unpaywall và web search không thấy bản truy cập mở của các bài còn lại trong danh sách này, cũng như của P04, P05, P07, P09, White & Simm 2003 và Herrera & van der Baan 2014. Có một ngoại lệ: Unpaywall báo `castagna2026quality` (TLE 2026, 10.1190/tle-2025-1058) là open access trên SEG Library, nhưng lệnh tải tự động bị từ chối, nên cần tải tay. Các bài cũng mới chỉ đọc abstract: `dacostasilva2026autotie` (10.1190/geo-2024-0011) và `herrera2014semiautomatic` (mục 12 ý 31 của plan).
**02/11/2026, sau đó:** người dùng tải tay thêm bốn bài, đã đổi tên theo key: `lim2025awsm.pdf` (sha256 56fd3a54…), `lim2025bootnet.pdf` (27846930…), `li2024bpinn.pdf` (f5d18e32…), `guillon2020gtmetrics.pdf` (2ea5af3c…). Toàn văn khớp với cách xếp trong Bảng `tab:positioning`. Chú thích ᵃ của bốn bài này và của hai bài Rizzuti đã bỏ (`docs/plan.md` mục 12 ý 33). Vẫn chỉ có abstract: `castagna2026quality` (open access, cần tải tay), `dacostasilva2026autotie`, `herrera2014semiautomatic`.
**Đóng ngày 02/11/2026 (quyết định của người dùng):** không tìm toàn văn thêm cho các bài còn lại (P04, P07, P09, White & Simm 2003, Herrera & van der Baan 2014, Autotie, Thiebaud, Cordoba, Mirza, Quesada, Huff). Các bài này giữ chú thích ᵃ. `castagna2026quality` (TLE 45(5) 378–390, CC BY) người dùng đã tải tay cùng ngày: `refs/castagna2026quality.pdf` (13 trang, sha256 5ec11aa1…), đã đọc toàn văn (`docs/plan.md` mục 12 ý 33). Danh sách này đóng.
## Chưa xác định được bài ## Chưa xác định được bài

View File

@@ -139,12 +139,32 @@ footer{margin-top:32px;color:var(--mute);font-size:12px}
<p><b>Post hoc (chỉ để so thang, <code>scripts/25_p4_posthoc.py</code>):</b> dự đoán hằng số bằng trung bình PHIF của các giếng train có RMSE macro 6,03 (lowo) và 6,59 p.u. (slot), thấp hơn mọi mạng. Sai số do mức trung bình khác nhau giữa giếng (8,5–17,0 p.u.) chi phối; khác biệt giữa các phương pháp tie (≤ 0,25 p.u.) nhỏ so với sai số tổng 6–7 p.u. Phép so sánh G-D vì vậy không có lực phân biệt; Volve không phải bằng chứng ủng hộ hay chống RML.</p> <p><b>Post hoc (chỉ để so thang, <code>scripts/25_p4_posthoc.py</code>):</b> dự đoán hằng số bằng trung bình PHIF của các giếng train có RMSE macro 6,03 (lowo) và 6,59 p.u. (slot), thấp hơn mọi mạng. Sai số do mức trung bình khác nhau giữa giếng (8,5–17,0 p.u.) chi phối; khác biệt giữa các phương pháp tie (≤ 0,25 p.u.) nhỏ so với sai số tổng 6–7 p.u. Phép so sánh G-D vì vậy không có lực phân biệt; Volve không phải bằng chứng ủng hộ hay chống RML.</p>
<p class="sub">Deviation sau khóa (chỉ lịch chạy): nhánh σ_a chạy song song trên cuda:0 thay vì sau nhánh chính trên cuda:1; G-D của nhánh chính tính lại khi có đủ các nhánh trùng hệt. Không chạy lại, không đổi thiết kế. Chi tiết: <code>docs/plan.md</code> §12 ý 20–21.</p> <p class="sub">Deviation sau khóa (chỉ lịch chạy): nhánh σ_a chạy song song trên cuda:0 thay vì sau nhánh chính trên cuda:1; G-D của nhánh chính tính lại khi có đủ các nhánh trùng hệt. Không chạy lại, không đổi thiết kế. Chi tiết: <code>docs/plan.md</code> §12 ý 20–21.</p>
</div> </div>
<div class="card" style="margin-bottom:14px">
<b>Kết quả P6 benchmark (protocol_bench, realization 8–15) ngày 02/11: 9/11 verdict đạt; S2-H1 trượt ở trục rock physics và wavelet</b>
<p>Summarize bằng code đã khoá (<code>scripts/34_run_bench.py summarize</code>, 02:02 UTC), rồi đọc lại đúng lời phát biểu của protocol bằng <code>scripts/36_bench_verdicts.py</code> (ngoài lock, kiểm lock trước khi chạy). 9 claim, 11 verdict, không hiệu chỉnh family-wise. Tỉ số là band RMSE của B3d-Sa chia cho tie điểm tốt nhất, ở N = 4 / 16, trừ khi ghi khác.</p>
<div class="tw"><table><thead><tr><th>Verdict</th><th>Phát biểu (rút gọn)</th><th>Số liệu</th><th>Kết luận</th></tr></thead><tbody>
<tr><td>S1-H1</td><td>H2a mở rộng tới c = 1,5 ở R10</td><td>0,853 [0,805; 0,910] / 0,796 [0,762; 0,826]; đối thủ B3c-R</td><td>Đạt (code: null*)</td></tr>
<tr><td>S1-H2</td><td>Lợi ích bank tăng theo số giếng</td><td>13/13 họ rộng có r(16) &lt; r(2); ρ = −0,47, p &lt; 10⁻⁴</td><td>Đạt</td></tr>
<tr><td>S2-H1 rock physics</td><td>rp_L1, R10, c = 1</td><td>0,940 / 0,934; ΔPCC +0,044 / +0,041; cải thiện ở 2/5 và 1/5 seed</td><td>Không đạt (dự đoán đạt)</td></tr>
<tr><td>S2-H1 wavelet</td><td>wv_L1 (pha), R10, c = 1</td><td>1,023 / 1,042 so với B3c; posterior quá tự tin (cov90 0,17 / 0,10; warp RMSE 2,6 / 2,3 ms so với σ_post 0,7 ms)</td><td>Không đạt (dự đoán đạt)</td></tr>
<tr><td>S2-H1 drift</td><td>dr_L1, R10, c = 1</td><td>0,862 / 0,798</td><td>Đạt (dự đoán: không chắc)</td></tr>
<tr><td>S2-H2</td><td>M2-Sa không hại dưới sai mô hình</td><td>14/14 cặp (preset, regime) ≤ 1,02; lớn nhất 1,0199 (R10 wv_L1)</td><td>Đạt</td></tr>
<tr><td>S3-H1</td><td>H2a giữ khi thêm B4a–d làm đối thủ</td><td>R10 0,857 / 0,782; R0 0,888 / 0,888; Rm5 0,915 / 0,923; R0h, R10tb không đạt</td><td>Đạt, phạm vi R10, R0, Rm5 (code: không đạt*)</td></tr>
<tr><td>S4-H1</td><td>H2a với backbone TCN, R10 c = 1</td><td>0,840 / 0,823</td><td>Đạt</td></tr>
<tr><td>S4-H2</td><td>Bank với TCN ở hai ô rộng</td><td>M2-Sa/B3d-Sa: R0h 0,977, Rm5 0,983</td><td>Đạt</td></tr>
<tr><td>S8-H1</td><td>Đảo dấu hàm truyền ở Δ = 32 ms (Hệ quả 3)</td><td>Ĥ trung bình trong băng đảo dấu −0,70 / −0,49</td><td>Đạt</td></tr>
<tr><td>S8-H2</td><td>Bank hai mode hơn nhãn trung bình</td><td>BK2/PM2: R10 0,34 (Δ 16), 0,28 (Δ 32); Rm5 0,71, 0,64</td><td>Đạt</td></tr>
</tbody></table></div>
<p>* Code tổng hợp đã khoá khác lời phát biểu ở ba chỗ. S1-H1: code cần đúng 2 dòng ở R10 c = 1,5 nhưng S1 có 4 giá trị N nên trả null. S2-H1: code tính đúng từng trục nhưng <code>summary.md</code> in "not available". S3-H1: code đưa Ctl-GP (bank nhiễu GP cùng trung bình và hiệp phương sai posterior, thêm có công bố từ T2) vào tập đối thủ. Ctl-GP gần như trùng B3d-Sa (tỉ số 0,90–1,01 ở c = 1), nên B3d-Sa không thể hơn nó 10%; theo code S3-H1 trượt ở mọi regime. Cả hai cách đọc đều được báo cáo (D-13).</p>
<p>Mô tả: wv_L2 trượt như dự đoán (1,22 / 1,39); ô băng thông wv_Q chỉ đạt ở N = 16 (0,927 / 0,842). Ở Rm5 mọi preset đạt luật ô, trừ rp_L2 ở N = 4. B4a–d không là đối thủ tốt nhất ở ô c ≤ 1 nào. T2-1 (có công bố): M2-Sa hơn Ctl-GP ở 12/30 ô (c = 0: 2, c = 1: 3, c = 2: 7). S8 Δ = 8 ms: BK2/PM2 0,60–0,98.</p>
<p class="sub"><a href="outputs/bench/summary/verdict_final.md">Verdict cuối</a> · <a href="outputs/bench/summary/summary.md">Bảng tổng hợp</a> · <a href="outputs/bench/summary/verdict.json">verdict.json (code đã khoá)</a>. Chi tiết: <code>docs/plan.md</code> §12 ý 28.</p>
</div>
<div id="phases"></div> <div id="phases"></div>
<h2>Các mục cần xác minh [XM]</h2> <h2>Các mục cần xác minh [XM]</h2>
<div class="tw"><table id="xm"><thead><tr><th>Mục</th><th>Vị trí trong plan</th><th>Trạng thái</th><th>Kết quả hoặc việc còn lại</th></tr></thead><tbody></tbody></table></div> <div class="tw"><table id="xm"><thead><tr><th>Mục</th><th>Vị trí trong plan</th><th>Trạng thái</th><th>Kết quả hoặc việc còn lại</th></tr></thead><tbody></tbody></table></div>
<h2>Quyết định (D-1 đến D-4 chốt 26/10/2026; D-5 đến D-12 chốt 29/10/2026)</h2> <h2>Quyết định (D-1 đến D-4 chốt 26/10/2026; D-5 đến D-12 chốt 29/10/2026; D-13 chốt 02/11/2026)</h2>
<div class="tw"><table id="dec"><thead><tr><th>Mã</th><th>Quyết định</th><th>Chốt</th><th>Căn cứ</th></tr></thead><tbody></tbody></table></div> <div class="tw"><table id="dec"><thead><tr><th>Mã</th><th>Quyết định</th><th>Chốt</th><th>Căn cứ</th></tr></thead><tbody></tbody></table></div>
<h2>Phát hiện đã kiểm chứng (từ dữ liệu)</h2> <h2>Phát hiện đã kiểm chứng (từ dữ liệu)</h2>
@@ -292,7 +312,7 @@ const PHASES = [
{id:"p4-p4x", t:"P4x exploratory (biến thể chọn sau khi thấy nhãn test)", s:"done", n:"Bỏ hẳn ngày 29/10/2026 (quyết định D-10): không tổng hợp, không vào bài, không chạy V3. Job exploratory/run_p4x.sh trên cuda:0 ở 560/921 khi chốt; sau đó dừng ở 670/921 (khoảng 04:05 UTC) và kill để trả GPU, nhánh B3d-Sa và V3 chưa chạy; kết quả không dùng. exploratory/ và outputs/p4x/ giữ làm hồ sơ."} {id:"p4-p4x", t:"P4x exploratory (biến thể chọn sau khi thấy nhãn test)", s:"done", n:"Bỏ hẳn ngày 29/10/2026 (quyết định D-10): không tổng hợp, không vào bài, không chạy V3. Job exploratory/run_p4x.sh trên cuda:0 ở 560/921 khi chốt; sau đó dừng ở 670/921 (khoảng 04:05 UTC) và kill để trả GPU, nhánh B3d-Sa và V3 chưa chạy; kết quả không dùng. exploratory/ và outputs/p4x/ giữ làm hồ sơ."}
]}, ]},
{id:"P5", name:"P5 Viết bài", start:"2026-10-29", end:"2026-10-31", weeks:"T5–T7 29–31/10", {id:"P5", name:"P5 Viết bài", start:"2026-10-29", end:"2026-10-31", weeks:"T5–T7 29–31/10",
out:"mức A của Pivot 1: khung bài mới, các mệnh đề rẻ, T3/T4 trên số liệu đã có (xong 29/10); trích dẫn dataset 30–31/10 (lượt rút gọn độ dài đã bỏ, D-12)", gate:null, out:"mức A của Pivot 1: khung bài mới, các mệnh đề rẻ, T3/T4 trên số liệu đã có (xong 29/10); trích dẫn dataset (xong 02/11; lượt rút gọn độ dài đã bỏ, D-12)", gate:null,
tasks:[ tasks:[
{id:"p5-d1", t:"Draft v1 và quyết định Pivot 1", s:"done", n:"29/10: đã viết đủ các mục Volve (dữ liệu, G-D, bảng tab:volvegd/volveall/volvesens, thảo luận, abstract, mở đầu, kết luận); bài build sạch, 42 trang. Trục bài đặt vào lý thuyết (Mệnh đề 1–2) và benchmark synthetic P2r; F3 và Volve là kiểm tra thực tế giới hạn phạm vi claim. Còn: citation dữ liệu, tác giả, rà văn phong. 29/10: chốt Pivot 1 (D-5 đến D-10), dời hạn sang 14/11; khảo sát dataset field public (docs/research/field-dataset-survey.md): chưa có dataset nào xác nhận đủ điều kiện cho field test có power, không thêm field test trong bài này."}, {id:"p5-d1", t:"Draft v1 và quyết định Pivot 1", s:"done", n:"29/10: đã viết đủ các mục Volve (dữ liệu, G-D, bảng tab:volvegd/volveall/volvesens, thảo luận, abstract, mở đầu, kết luận); bài build sạch, 42 trang. Trục bài đặt vào lý thuyết (Mệnh đề 1–2) và benchmark synthetic P2r; F3 và Volve là kiểm tra thực tế giới hạn phạm vi claim. Còn: citation dữ liệu, tác giả, rà văn phong. 29/10: chốt Pivot 1 (D-5 đến D-10), dời hạn sang 14/11; khảo sát dataset field public (docs/research/field-dataset-survey.md): chưa có dataset nào xác nhận đủ điều kiện cho field test có power, không thêm field test trong bài này."},
{id:"p5-a1", t:"Viết lại abstract, mở đầu, đóng góp, thảo luận, kết luận theo trục lý thuyết + benchmark", s:"done", n:"Xong sớm ngày 29/10 (plan §12 ý 24). Tiêu đề theo Pivot 1 (kèm TODO: đổi benchmark thành controlled synthetic study nếu S2 không kịp), abstract 292 từ (sau lượt tự sửa A6), keywords, paper/highlights.txt, đóng góp C1–C4. F3 và Volve thành mục phạm vi 6.6; chi tiết sang Phụ lục B (B.1 F3, B.2 Volve). Bài 55 trang (sau A6), build sạch; còn TODO đỏ cho S1–S8, T2 và các khai báo của tác giả."}, {id:"p5-a1", t:"Viết lại abstract, mở đầu, đóng góp, thảo luận, kết luận theo trục lý thuyết + benchmark", s:"done", n:"Xong sớm ngày 29/10 (plan §12 ý 24). Tiêu đề theo Pivot 1 (kèm TODO: đổi benchmark thành controlled synthetic study nếu S2 không kịp), abstract 292 từ (sau lượt tự sửa A6), keywords, paper/highlights.txt, đóng góp C1–C4. F3 và Volve thành mục phạm vi 6.6; chi tiết sang Phụ lục B (B.1 F3, B.2 Volve). Bài 55 trang (sau A6), build sạch; còn TODO đỏ cho S1–S8, T2 và các khai báo của tác giả."},
@@ -301,28 +321,29 @@ const PHASES = [
{id:"p5-a4", t:"T3: khả năng phát hiện của field test (giải tích + mô phỏng trên dự đoán P2r)", s:"done", n:"29/10, exploratory, khai báo trước ở docs/research/applicability-teapot.md (Deviation 1: mở rộng lưới σ_ref). scripts/27_t3_power.py → outputs/t3/ (bài mục 6.5, bảng tab:t3). Khác phác thảo: reference là nhãn thật đọc tại warp nhiễu loạn cỡ σ_ref, luật đánh giá là sign test một phía. Cần 5–18 giếng blind với reference chính xác; từ 3 ms không ô nào đạt với 40 giếng."}, {id:"p5-a4", t:"T3: khả năng phát hiện của field test (giải tích + mô phỏng trên dự đoán P2r)", s:"done", n:"29/10, exploratory, khai báo trước ở docs/research/applicability-teapot.md (Deviation 1: mở rộng lưới σ_ref). scripts/27_t3_power.py → outputs/t3/ (bài mục 6.5, bảng tab:t3). Khác phác thảo: reference là nhãn thật đọc tại warp nhiễu loạn cỡ σ_ref, luật đánh giá là sign test một phía. Cần 5–18 giếng blind với reference chính xác; từ 3 ms không ô nào đạt với 40 giếng."},
{id:"p5-a5", t:"T10: related work về label noise / errors-in-variables", s:"done", n:"29/10: đoạn Label noise and errors in variables ở bài mục 2 (Berkson 1950, Fuller 1987, Carroll et al. 2006, Frénay & Verleysen 2014, Song et al. 2023, Mnih & Hinton 2012 đọc toàn văn, Balakrishnan 1962 chỉ có metadata Crossref). Bảng định vị thêm Mnih & Hinton."}, {id:"p5-a5", t:"T10: related work về label noise / errors-in-variables", s:"done", n:"29/10: đoạn Label noise and errors in variables ở bài mục 2 (Berkson 1950, Fuller 1987, Carroll et al. 2006, Frénay & Verleysen 2014, Song et al. 2023, Mnih & Hinton 2012 đọc toàn văn, Balakrishnan 1962 chỉ có metadata Crossref). Bảng định vị thêm Mnih & Hinton."},
{id:"p5-app", t:"Điều kiện áp dụng C1–C4 và thử Teapot Dome (exploratory)", s:"done", n:"29/10, plan §12 ý 23. Khai báo trước ở docs/research/applicability-teapot.md; kết quả ở docs/research/applicability-results.md. C1/C2 hồi cứu (scripts/26): F3, Volve trượt C1, đạt C2. Teapot: T0 trượt (tối đa 2 giếng TD độc lập), pilot P-a trượt (σ̂_knot 6,75 ms so với 1,5 ms). Dừng Teapot, quay về lịch mức B (D-11). data/Teapot/ (1,7 GB) đã vào .gitignore."}, {id:"p5-app", t:"Điều kiện áp dụng C1–C4 và thử Teapot Dome (exploratory)", s:"done", n:"29/10, plan §12 ý 23. Khai báo trước ở docs/research/applicability-teapot.md; kết quả ở docs/research/applicability-results.md. C1/C2 hồi cứu (scripts/26): F3, Volve trượt C1, đạt C2. Teapot: T0 trượt (tối đa 2 giếng TD độc lập), pilot P-a trượt (σ̂_knot 6,75 ms so với 1,5 ms). Dừng Teapot, quay về lịch mức B (D-11). data/Teapot/ (1,7 GB) đã vào .gitignore."},
{id:"p5-cite", t:"Trích dẫn dataset F3 và Volve", s:"todo", n:"30–31/10: thêm vào paper/refs.bib và mục 3 của bài. Lượt rút gọn độ dài cho venue đã bỏ theo quyết định của người dùng ngày 29/10 (D-12)."}, {id:"p5-cite", t:"Trích dẫn dataset F3 và Volve", s:"done", n:"Xong 02/11 (plan §12 ý 30): paper/refs.bib thêm dgb2023f3demo (F3 Demo 2023, dGB Earth Sciences, TerraNubis, CC BY-SA 3.0) và equinor2018volve (Volve, Equinor 2018; file giấy phép ghi CC BY-NC-SA 4.0); trích ở Sec. 3.1, 3.3 và mục availability của Sec. 8. Lượt rút gọn độ dài cho venue đã bỏ theo quyết định của người dùng ngày 29/10 (D-12)."},
{id:"p5-d2", t:"Draft v2, phụ lục chứng minh", s:"todo", n:"Dời sang 8–10/11 theo lịch mức B."}, {id:"p5-d2", t:"Draft v2, phụ lục chứng minh", s:"done", n:"Draft v2 về nội dung đã có từ 02/11: Thí nghiệm 3 (Sec. 6.5), T2 (Sec. 6.4) và trích dẫn dataset (plan §12 ý 30). Rà phụ lục chứng minh xong sớm ngày 02/11 (plan §12 ý 32): một agent con đọc độc lập Sec. 4, App. A và Bổ đề 5, trả 15 điểm; sửa 14 điểm, sửa một phần điểm còn lại (giữ tên cận B_a/B_b đã đăng ký). Các sửa chính: (A2) cần sup_t; (B) chỉ dịch nguyên mẫu, kèm ví dụ khi đúng; sd(β) là có điều kiện dọc ridge; khai triển Mệnh đề 4 là hình thức; bank ±Δ/2 trọng số bằng nhau ở Hệ quả 3 chứa warp thật nhưng không hiệu chỉnh; Hệ quả 4 (phương pháp đổi tên 1/2): σ_r < σ/√2 là điều kiện cần ở mọi tần số nhưng không đủ, nên Sec. 6.6 sửa lại so sánh điểm cắt 3,6/3,8/4,3 ms. Không verdict hay số đã báo cáo nào đổi. docs/theory.md đồng bộ. Bài 67 trang, không warning."},
{id:"p5-repro", t:"Gói tái lập (code, config, dữ liệu dẫn xuất)", s:"todo", n:"Dời sang 11–12/11."} {id:"p5-repro", t:"Gói tái lập (code, config, dữ liệu dẫn xuất)", s:"done", n:"Xong sớm ngày 02/11, trừ bước deposit (plan §12 ý 32). scripts/39_repro_package.py (ngoài mọi lock): build → 5 archive tất định trong outputs/repro/ (f3_results 164 MB, f3_predictions 2,11 GB, f3_volume 505 MB: CC BY-SA 3.0; volve 8,9 MB: CC BY-NC-SA 4.0; teapot 95 KB: CC0, cần kiểm) và repro/MANIFEST.json (11.112 file, sha256 từng file); check; verify (phòng sạch không có dữ liệu thô, 12 bước, audit hook, so byte/giá trị/pixel) → repro/verify_report.md: chạy 02/11 (20 phút, CPU), 12/12 bước exit 0, không đọc file ngoài phòng sạch; 63 file trùng byte (8 hình trùng từng pixel), 3 file trùng giá trị, 0 file khác; tests/test_d2_misspec.py qua 15/15 trong phòng sạch; code --rev. Hướng dẫn tiếng Anh: repro/README.md; môi trường: repro/requirements-linux.txt. Còn: deposit và giấy phép code (người dùng), xác nhận giấy phép của bảng applicability gộp F3 và Volve."}
]}, ]},
{id:"P6", name:"P6 Benchmark mức B", start:"2026-11-01", end:"2026-11-10", weeks:"CN 1/11 – T3 10/11", {id:"P6", name:"P6 Benchmark mức B", start:"2026-11-01", end:"2026-11-10", weeks:"CN 1/11 – T3 10/11",
out:"protocol_bench khoá trước khi chạy; lưới đầy; trục misspec; phân tích cơ chế; gói benchmark", gate:null, out:"protocol_bench khoá trước khi chạy; lưới đầy; trục misspec; phân tích cơ chế; gói benchmark; các mục kết quả trong bài (xong 02/11, trừ deposit Zenodo)", gate:null,
tasks:[ tasks:[
{id:"p6-t2", t:"T2 cơ chế của lợi ích bank (exploratory, realization 8–15)", s:"done", n:"Xong 29/10 (12:39–13:27 UTC; exploratory, realization 8–15). Khai báo băm trước mọi tính toán (f04e6607…), không sai lệch. Kiểm tái lập: huấn luyện lại khớp RMSE đã đăng ký, max |dev| = 0 trên 10.560 dòng. (i) warp trọng số responsibility thấp hơn warp trung bình ở 8/8 ô rộng (giảm 13–40 %): tái định vị ngầm có thật trên giếng train. (ii) bank nhiễu GP cùng hiệp phương sai đạt phần lớn lợi ích ở c = 1 (4/8 'phù hợp (a)', 3/8 'một phần', 1/8 'ngược'); thông tin của bank SMC cần ở c = 2. (iii) không có bằng chứng cho cơ chế đa mode theo luật chính. (iv) sai số nhãn của B3d-Sa là Berkson ở c = 1 (4/4 ô rộng) nên cận 1/B_b áp dụng; lợi ích H2b không vượt hiệu chỉnh quần thể. (v) khoảng một phần ba khoảng cách PM–Oracle ở c = 1 là do độ dài huấn luyện. Chi tiết: docs/research/t2-results.md, outputs/t2/summary.md. Không đổi H2a/H2b; không dùng để chọn lại budget."}, {id:"p6-t2", t:"T2 cơ chế của lợi ích bank (exploratory, realization 8–15)", s:"done", n:"Xong 29/10 (12:39–13:27 UTC; exploratory, realization 8–15). Khai báo băm trước mọi tính toán (f04e6607…), không sai lệch. Kiểm tái lập: huấn luyện lại khớp RMSE đã đăng ký, max |dev| = 0 trên 10.560 dòng. (i) warp trọng số responsibility thấp hơn warp trung bình ở 8/8 ô rộng (giảm 13–40 %): tái định vị ngầm có thật trên giếng train. (ii) bank nhiễu GP cùng hiệp phương sai đạt phần lớn lợi ích ở c = 1 (4/8 'phù hợp (a)', 3/8 'một phần', 1/8 'ngược'); thông tin của bank SMC cần ở c = 2. (iii) không có bằng chứng cho cơ chế đa mode theo luật chính. (iv) sai số nhãn của B3d-Sa là Berkson ở c = 1 (4/4 ô rộng) nên cận 1/B_b áp dụng; lợi ích H2b không vượt hiệu chỉnh quần thể. (v) khoảng một phần ba khoảng cách PM–Oracle ở c = 1 là do độ dài huấn luyện. Chi tiết: docs/research/t2-results.md, outputs/t2/summary.md. Không đổi H2a/H2b; không dùng để chọn lại budget."},
{id:"p6-gen", t:"Sửa generator cho S2 (misspec rock physics, wavelet, σ_b/drift); dev trên realization 902–905", s:"done", n:"Xong sớm 29/10: tham số misspec trong synth_d2.py (rock_physics, wavelet, drift; misspec=None tái lập fingerprint P2r từng bit; 15 test mới), configs/d2_synth_bench.yaml (preset còn PLACEHOLDER), script 33 QC, docs/research/bench-generator.md. QC rid 902: rp_C bị likelihood α-profile hấp thụ hoàn toàn (chỉ làm đối chứng); wv_L1/L2 quá mạnh (model error 0.6 so với nhiễu R10 0.32). QC SMC rid 902 (cuda:1, 32 phút): đối chứng rp_C và wv_C đúng dự đoán; pha wavelet phụ thuộc tần số (minphase 1.0) là kiểu hỏng mạnh nhất và quá tự tin ở R10 (warp RMSE 4.2 ms, cov90 0.04, kém hơn tie chỉ anchor); rock physics phân tán theo đơn vị chỉ thấy ở R10; hai preset drift nhân đôi sai số ở R10 nhưng vẫn gần hiệu chỉnh. Mức chính chốt ở bước dev của p6-lock. T2 2/11 – T3 3/11. Đường mặc định của D2 phải tái lập đúng P2r."}, {id:"p6-gen", t:"Sửa generator cho S2 (misspec rock physics, wavelet, σ_b/drift); dev trên realization 902–905", s:"done", n:"Xong sớm 29/10: tham số misspec trong synth_d2.py (rock_physics, wavelet, drift; misspec=None tái lập fingerprint P2r từng bit; 15 test mới), configs/d2_synth_bench.yaml (preset còn PLACEHOLDER), script 33 QC, docs/research/bench-generator.md. QC rid 902: rp_C bị likelihood α-profile hấp thụ hoàn toàn (chỉ làm đối chứng); wv_L1/L2 quá mạnh (model error 0.6 so với nhiễu R10 0.32). QC SMC rid 902 (cuda:1, 32 phút): đối chứng rp_C và wv_C đúng dự đoán; pha wavelet phụ thuộc tần số (minphase 1.0) là kiểu hỏng mạnh nhất và quá tự tin ở R10 (warp RMSE 4.2 ms, cov90 0.04, kém hơn tie chỉ anchor); rock physics phân tán theo đơn vị chỉ thấy ở R10; hai preset drift nhân đôi sai số ở R10 nhưng vẫn gần hiệu chỉnh. Mức chính chốt ở bước dev của p6-lock. T2 2/11 – T3 3/11. Đường mặc định của D2 phải tái lập đúng P2r."},
{id:"p6-lock", t:"Viết và khoá configs/protocol_bench.yaml (S1, S2, S3, S4, S8)", s:"done", n:"Khoá 29/10 lúc 14:39 UTC (sha256 aa763f0a…; code_sha256 5ea2eb17…; 8 input, 102 artifact tham chiếu P2r, fingerprint danh nghĩa rid 8 và 902 khớp). Runner ml_porosity/benchmark/, scripts 34–35, scripts/run_bench.sh; 216 test pass. Tái lập ô P2r (R10, rid 8, c = 1, N = 4) qua runner: khớp từng bit. Mức S2 chốt trên dev 902–905: rock physics sd 0.10/0.15 theo đơn vị; wavelet minphase 0.5/1.0 và ô Q 80 riêng; drift hai cơ chế (siêu tham số sai; bước 8 ms + jitter 1 ms). rp_L1 (×1.24 nhiễu R10) và wv_L1 (×1.08) vượt dải L1 khai báo 0.5–1.0×, đã công bố trong protocol. Ở Rm5 khai báo trước kết quả null. Budget TCN chọn trên dev bằng luật protocol_p2: 125 vòng cho mọi phương pháp (nằm ở biên danh sách ứng viên, ghi rõ). Ô: S1 560 job SMC, S2 224, S3 240, S4 48, S8 96; thêm có công bố Ctl-GP và nhánh cùng budget 500. 9 claim khai báo trước, 11 verdict, không hiệu chỉnh family-wise, báo cáo mọi verdict. Thiết kế sau khi đã thấy P2r."}, {id:"p6-lock", t:"Viết và khoá configs/protocol_bench.yaml (S1, S2, S3, S4, S8)", s:"done", n:"Khoá 29/10 lúc 14:39 UTC (sha256 aa763f0a…; code_sha256 5ea2eb17…; 8 input, 102 artifact tham chiếu P2r, fingerprint danh nghĩa rid 8 và 902 khớp). Runner ml_porosity/benchmark/, scripts 34–35, scripts/run_bench.sh; 216 test pass. Tái lập ô P2r (R10, rid 8, c = 1, N = 4) qua runner: khớp từng bit. Mức S2 chốt trên dev 902–905: rock physics sd 0.10/0.15 theo đơn vị; wavelet minphase 0.5/1.0 và ô Q 80 riêng; drift hai cơ chế (siêu tham số sai; bước 8 ms + jitter 1 ms). rp_L1 (×1.24 nhiễu R10) và wv_L1 (×1.08) vượt dải L1 khai báo 0.5–1.0×, đã công bố trong protocol. Ở Rm5 khai báo trước kết quả null. Budget TCN chọn trên dev bằng luật protocol_p2: 125 vòng cho mọi phương pháp (nằm ở biên danh sách ứng viên, ghi rõ). Ô: S1 560 job SMC, S2 224, S3 240, S4 48, S8 96; thêm có công bố Ctl-GP và nhánh cùng budget 500. 9 claim khai báo trước, 11 verdict, không hiệu chỉnh family-wise, báo cáo mọi verdict. Thiết kế sau khi đã thấy P2r."},
{id:"p6-s1", t:"S1: lấp lưới c ∈ {0.5, 1.5}, N ∈ {2, 8}", s:"done", n:"Xong 02:16 UTC 30/10: 560/560 ô train (R10, Rm5, R0, R0h, R10tb × 112), posterior SMC xong trước đó. Bị SIGTERM 15:27 UTC 29/10, chạy lại trong tmux từ 16:07; 01:02 UTC 30/10 tách nhóm B thành hai driver R0h và R10tb (tổng 36 worker, CPU bão hòa). R10tb xong 01:50, nhóm A 01:57, R0h 02:16. Supervisor hai lần khởi động lại R0h khi dồn worker (01:53, 01:58), mất khoảng 10 phút job dở; không ảnh hưởng kết quả (resume theo fingerprint). Chưa summarize."}, {id:"p6-s1", t:"S1: lấp lưới c ∈ {0.5, 1.5}, N ∈ {2, 8}", s:"done", n:"Xong 02:16 UTC 30/10: 560/560 ô train (R10, Rm5, R0, R0h, R10tb × 112), posterior SMC xong trước đó. Bị SIGTERM 15:27 UTC 29/10, chạy lại trong tmux từ 16:07; 01:02 UTC 30/10 tách nhóm B thành hai driver R0h và R10tb (tổng 36 worker, CPU bão hòa). R10tb xong 01:50, nhóm A 01:57, R0h 02:16. Supervisor hai lần khởi động lại R0h khi dồn worker (01:53, 01:58), mất khoảng 10 phút job dở; không ảnh hưởng kết quả (resume theo fingerprint). Summarize 02/11: S1-H1 đạt (R10 c = 1.5: 0.853 / 0.796 ở N = 4/16), S1-H2 đạt (13/13 họ rộng, ρ = −0.47, p < 10⁻⁴)."},
{id:"p6-s3s4", t:"S3: B4 dưới posterior SMC; S4: backbone thứ hai", s:"done", n:"Xong 00:58 UTC 30/10: train S3+S4+S8 đủ 384/384 job (tmux p6_s348, wall 8:50:41 từ 16:07 UTC). S4 dùng TCN, budget 125. Chưa summarize."}, {id:"p6-s3s4", t:"S3: B4 dưới posterior SMC; S4: backbone thứ hai", s:"done", n:"Xong 00:58 UTC 30/10: train S3+S4+S8 đủ 384/384 job (tmux p6_s348, wall 8:50:41 từ 16:07 UTC). S4 dùng TCN, budget 125. Summarize 02/11: S3-H1 đạt theo phát biểu ở R10, R0, Rm5 (không đạt ở R0h, R10tb); code đã khoá đưa Ctl-GP vào đối thủ nên báo không đạt, báo cáo cả hai (D-13). S4-H1 đạt (0.840 / 0.823), S4-H2 đạt (0.977 / 0.983)."},
{id:"p6-s2", t:"S2: ba trục misspec ở R10, Rm5, c = 1, N ∈ {4, 16}", s:"done", n:"Xong 00:12 UTC 30/10: posterior 224/224, train 224/224 (tmux p6_s2, cuda:1, 6 worker). Bắt buộc (D-7): thiếu S2 thì bài gọi là controlled synthetic study, không gọi là benchmark. Chưa summarize."}, {id:"p6-s2", t:"S2: ba trục misspec ở R10, Rm5, c = 1, N ∈ {4, 16}", s:"done", n:"Xong 00:12 UTC 30/10: posterior 224/224, train 224/224 (tmux p6_s2, cuda:1, 6 worker). Bắt buộc (D-7): thiếu S2 thì bài gọi là controlled synthetic study, không gọi là benchmark. S2 đủ nên được gọi là benchmark. Summarize 02/11: S2-H1 đạt ở trục drift (0.862 / 0.798), không đạt ở rock physics (0.940 / 0.934) và wavelet (1.023 / 1.042), trái dự đoán; S2-H2 đạt (14/14 cặp ≤ 1.02)."},
{id:"p6-s8", t:"S8/T8: regime cycle-skip có kiểm soát", s:"done", n:"Xong 00:58 UTC 30/10, chung job với S3, S4 (tmux p6_s348). Chưa summarize."}, {id:"p6-s8", t:"S8/T8: regime cycle-skip có kiểm soát", s:"done", n:"Xong 00:58 UTC 30/10, chung job với S3, S4 (tmux p6_s348). Summarize 02/11: S8-H1 đạt (Ĥ trung bình −0.70 / −0.49 ở Δ = 32 ms), S8-H2 đạt (BK2/PM2 0.28–0.71 ở 4/4 ô)."},
{id:"p6-s7", t:"S7: đóng gói benchmark (một lệnh sinh, một lệnh chấm, bảng tham chiếu, README, hash, Zenodo)", s:"todo", n:"CN 8/11 – T3 10/11."}, {id:"p6-sum", t:"Summarize và đọc 11 verdict theo lời phát biểu (scripts/34 summarize, scripts/36)", s:"done", n:"Xong 02/11. Summarize theo code đã khoá 02:02 UTC (lock khớp, 8.799 file khớp sha256) → outputs/bench/summary/. scripts/36_bench_verdicts.py (ngoài lock, kiểm lock trước khi chạy) đọc lại đúng lời phát biểu → verdict_final.json, verdict_final.md: 9/11 đạt; S2-H1 trượt ở rock physics và wavelet. Ba chỗ code khác phát biểu (S1-H1, S2-H1, S3-H1), chỉ S3-H1 đổi kết luận (D-13)."},
{id:"p6-write", t:"Viết lại các mục kết quả theo số liệu mới", s:"todo", n:"CN 8/11 – T3 10/11."} {id:"p6-s7", t:"S7: đóng gói benchmark (một lệnh sinh, một lệnh chấm, bảng tham chiếu, README, hash, Zenodo)", s:"done", n:"Xong sớm 02/11, trừ bước deposit Zenodo (cần tài khoản và danh sách tác giả của người dùng). scripts/37_bench_package.py (ngoài lock; generate và tables kiểm lock trước). generate: 630 task (test 8–15, dev 900–905; mỗi realization 45 task: 5 regime × 5 c, 14 setting S2, 6 setting S8), truth ẩn, input, analyst.json → outputs/bench/package/ (845 MB). Hash nội dung trong benchmark/MANIFEST.json; chạy lại tái lập 1.260/1.260 hash, check khớp 1.265/1.265 file. tables: 45.200 run tham chiếu, 21 phương pháp → benchmark/reference/. score áp luật ô H2a và luật better của summary.py. selftest đạt: bản chép dự đoán B3d-Sa/BK2 đã lưu cho lại metric (lệch ≤ 5e-10) và luật (S1-H1 0,8529 / 0,7964). Hướng dẫn: benchmark/README.md (tiếng Anh). Metadata Zenodo nháp: benchmark/zenodo_metadata.json (giấy phép nháp CC BY-SA 3.0 theo F3, cần kiểm). plan.md §12 ý 29."},
{id:"p6-write", t:"Viết lại các mục kết quả theo số liệu mới", s:"done", n:"Xong sớm 02/11 (plan §12 ý 30). Sec. 6.5 mới, Thí nghiệm 3: bảng thiết kế và bảng 11 verdict với cả hai cách đọc (D-13); hình phase diagram S1; bảng S2 ghi rõ hai trục trượt (rock physics, pha wavelet); S3, S4; bảng và hình S8; nhánh cùng budget. Sec. 6.4 (T2) thay todoblock. Sec. 3.2 thêm preset misspec; Sec. 5 thêm TCN và các dòng benchmark của tab:methods. Cập nhật abstract, intro, discussion, kết luận, availability; bỏ TODO ở tiêu đề. Hình vẽ bằng scripts/38_bench_figures.py (ngoài lock). Chữ 'calibrated' của S8-H2 chỉ theo nghĩa yếu (truth là thành viên); bài ghi rõ BK2 không phải bank hiệu chỉnh theo Mệnh đề 4 (D-14). Nguồn số: paper/README.md."}
]}, ]},
{id:"P7", name:"P7 Review và nộp", start:"2026-11-11", end:"2026-11-14", weeks:"T4–T7 11–14/11", {id:"P7", name:"P7 Review và nộp", start:"2026-11-11", end:"2026-11-14", weeks:"T4–T7 11–14/11",
out:"bản nộp", gate:null, out:"bản nộp", gate:null,
tasks:[ tasks:[
{id:"p7-rev", t:"Review nội bộ; hình; phụ lục chứng minh; gói tái lập", s:"todo", n:"T4 11/11 – T5 12/11."}, {id:"p7-rev", t:"Review nội bộ; hình; phụ lục chứng minh; gói tái lập", s:"todo", n:"T4 11/11 – T5 12/11."},
{id:"p7-nov", t:"Kiểm tra tính mới lần cuối, tra quartile, đăng preprint", s:"todo", n:"T6 13/11."}, {id:"p7-nov", t:"Kiểm tra tính mới lần cuối, tra quartile, đăng preprint", s:"todo", n:"T6 13/11. Quét sơ bộ xong 02/11 (plan §12 ý 31): không bài nào đưa bất định tie vào huấn luyện; thêm Herrera 2014, Autotie 2026 (chỉ abstract) và Castagna 2026 (đọc toàn văn 02/11, plan §12 ý 33). Ngày 13/11: quét lại; abstract IMAGE 2026 của Palavicini Gurria; DOI Quesada 2024."},
{id:"p7-sub", t:"Nộp Computers & Geosciences", s:"todo", n:"T7 14/11."} {id:"p7-sub", t:"Nộp Computers & Geosciences", s:"todo", n:"T7 14/11."}
]} ]}
]; ];
@@ -336,9 +357,9 @@ const XM = [
{name:"Mốc thời gian của SEG-Y (delay 4 ms)", where:"mục 1.2, phát hiện khi làm P0", s:"todo", r:"F3_entire.segy ghi DelayRecordingTime = 4 ms (mẫu đầu ở 4 ms), trong khi .survey ghi trục Z bắt đầu từ 0. Cần xác nhận marker và horizon dùng cùng mốc, nếu không sẽ lệch đều 1 mẫu. Kiểm 26/10: horizon − marker tại giếng có trung vị +1.6 ms (FS8, Truncation lệch ≤ 2 ms); dịch chung của tie tốt nhất ở F03-4, F06-1 là +1 đến +7 ms. Chưa đủ để kết luận ở mức 4 ms."}, {name:"Mốc thời gian của SEG-Y (delay 4 ms)", where:"mục 1.2, phát hiện khi làm P0", s:"todo", r:"F3_entire.segy ghi DelayRecordingTime = 4 ms (mẫu đầu ở 4 ms), trong khi .survey ghi trục Z bắt đầu từ 0. Cần xác nhận marker và horizon dùng cùng mốc, nếu không sẽ lệch đều 1 mẫu. Kiểm 26/10: horizon − marker tại giếng có trung vị +1.6 ms (FS8, Truncation lệch ≤ 2 ms); dịch chung của tie tốt nhất ở F03-4, F06-1 là +1 đến +7 ms. Chưa đủ để kết luận ở mức 4 ms."},
{name:"Kiểm kê NLOG", where:"D1, mục 5.1", s:"done", r:"F03-03 và F03-06 dùng được; F03-05-S1 không (dữ liệu thời gian–độ sâu bắt đầu ở 1295 ms)."}, {name:"Kiểm kê NLOG", where:"D1, mục 5.1", s:"done", r:"F03-03 và F03-06 dùng được; F03-05-S1 không (dữ liệu thời gian–độ sâu bắt đầu ở 1295 ms)."},
{name:"Kiểm kê Volve", where:"D3, mục 5.1", s:"done", r:"Xong phần cục bộ: toạ độ, quỹ đạo, ROI. Horizon và well picks tải ngày 26/10 (marker TWT cho cả 10 giếng). Cube ST10010 đã tải và kiểm tra."}, {name:"Kiểm kê Volve", where:"D3, mục 5.1", s:"done", r:"Xong phần cục bộ: toạ độ, quỹ đạo, ROI. Horizon và well picks tải ngày 26/10 (marker TWT cho cả 10 giếng). Cube ST10010 đã tải và kiểm tra."},
{name:"Quét SEG/EAGE 2024–2026", where:"mục 2.4 (4)", s:"done", r:"Xong ngày 28/10/2026. Thêm 10 bài chỉ có abstract (AWSM, BootNet, Quesada, Mirza, Guillon, Cordoba, Thiebaud, Rizzuti ×2, Huff) vào paper/refs.bib và §2. Không bài nào đưa posterior của tie vào huấn luyện; câu 'to our knowledge' giữ nguyên. Còn mở: abstract IMAGE 2026 của Palavicini Gurria et al., DOI của Quesada 2024."}, {name:"Quét SEG/EAGE 2024–2026", where:"mục 2.4 (4)", s:"done", r:"Xong ngày 28/10/2026. Thêm 10 bài chỉ có abstract (AWSM, BootNet, Quesada, Mirza, Guillon, Cordoba, Thiebaud, Rizzuti ×2, Huff) vào paper/refs.bib và §2. Không bài nào đưa posterior của tie vào huấn luyện; câu 'to our knowledge' giữ nguyên. Còn mở: abstract IMAGE 2026 của Palavicini Gurria et al., DOI của Quesada 2024 (ngày 02/11 vẫn chưa lấy được; quét sơ bộ 02/11 ở plan §12 ý 31). Ngày 02/11 đã có toàn văn hai bài Rizzuti (refs/), khớp với Bảng tab:positioning; các bài khác không có bản truy cập mở (refs/MISSING.md). Cùng ngày người dùng tải tay AWSM, BootNet, P05 và Guillon 2020: toàn văn khớp với bảng, AWSM có 44 giếng và không bước nào dùng posterior TD; bỏ chú thích ᵃ của sáu bài (plan §12 ý 33)."},
{name:"Đặt Google Scholar alert", where:"mục 2.4 (5)", s:"todo", r:"Làm cùng bước quét; nhắc lại trước khi nộp."}, {name:"Đặt Google Scholar alert", where:"mục 2.4 (5)", s:"todo", r:"Làm cùng bước quét; nhắc lại trước khi nộp."},
{name:"5 bài mới đọc được abstract (P03, P04, P05, P07, P09)", where:"mục 2.2", s:"done", r:"Đóng ngày 28/10/2026. P03 có toàn văn (refs/xu2024sts.pdf). P04, P05, P07, P09 không lấy được toàn văn; mọi chỗ trích trong bản thảo đã đối chiếu với abstract và đều khớp; giữ chú thích abstract-only."}, {name:"5 bài mới đọc được abstract (P03, P04, P05, P07, P09)", where:"mục 2.2", s:"done", r:"Đóng ngày 28/10/2026. P03 có toàn văn (refs/xu2024sts.pdf). P04, P05, P07, P09 không lấy được toàn văn; mọi chỗ trích trong bản thảo đã đối chiếu với abstract và đều khớp; giữ chú thích abstract-only. Ngày 02/11 người dùng tải tay được P05 (refs/li2024bpinn.pdf): toàn văn khớp, bỏ chú thích ᵃ (plan §12 ý 33)."},
{name:"Quartile SJR của venue", where:"dòng 28, mục 8", s:"todo", r:"Tra SCImago khi nộp bài."}, {name:"Quartile SJR của venue", where:"dòng 28, mục 8", s:"todo", r:"Tra SCImago khi nộp bài."},
{name:"Xếp hạng CORE của hội nghị", where:"mục 8", s:"todo", r:"Tra portal.core.edu.au (ICANN, ICONIP)."}, {name:"Xếp hạng CORE của hội nghị", where:"mục 8", s:"todo", r:"Tra portal.core.edu.au (ICANN, ICONIP)."},
{name:"Gunning & Glinsky (2006), Wavelet extractor", where:"mục 2.4 (2), mục 11", s:"done", r:"Đã đọc toàn văn ngày 26/10/2026 (refs/gunning2006waveletextractor.pdf). Tóm tắt ở plan mục 2.1 L1; bib gunning2006waveletextractor."}, {name:"Gunning & Glinsky (2006), Wavelet extractor", where:"mục 2.4 (2), mục 11", s:"done", r:"Đã đọc toàn văn ngày 26/10/2026 (refs/gunning2006waveletextractor.pdf). Tóm tắt ở plan mục 2.1 L1; bib gunning2006waveletextractor."},
@@ -357,7 +378,9 @@ const DECISIONS = [
{id:"D-9", q:"Venue", p:"Computers & Geosciences; dự phòng Geophysical Prospecting.", n:"Nhận bài benchmark kèm code, yêu cầu code/data availability (khớp S7). Quartile tra lại khi nộp [XM]."}, {id:"D-9", q:"Venue", p:"Computers & Geosciences; dự phòng Geophysical Prospecting.", n:"Nhận bài benchmark kèm code, yêu cầu code/data availability (khớp S7). Quartile tra lại khi nộp [XM]."},
{id:"D-10", q:"Số phận P4x", p:"Bỏ hẳn. Không dùng trong bài, không chạy V3, không tổng hợp; exploratory/ và outputs/p4x/ giữ làm hồ sơ.", n:"Không phục vụ bài mới; biến thể chọn sau khi thấy nhãn test. Người dùng chốt."}, {id:"D-10", q:"Số phận P4x", p:"Bỏ hẳn. Không dùng trong bài, không chạy V3, không tổng hợp; exploratory/ và outputs/p4x/ giữ làm hồ sơ.", n:"Không phục vụ bài mới; biến thể chọn sau khi thấy nhãn test. Người dùng chốt."},
{id:"D-11", q:"Teapot Dome làm field test thứ ba?", p:"Không. Dừng Teapot, giữ Pivot 1 và lịch mức B; T3 và C1–C4 vào bài như phân tích exploratory về điều kiện cần của một field test, không phải claim.", n:"T0: chỉ 4 bảng TD, tối đa 2 giếng độc lập (cần ≥ 3 cho C3 cộng 11–18 cho C4). Pilot P-a (knot horizon–top, 37 giếng dev, chưa mở porosity): σ̂_knot 6,75 ms (CI 90% 4,1–9,4) so với dung sai 1,5 ms. Người dùng chốt: quay về lịch mức B."}, {id:"D-11", q:"Teapot Dome làm field test thứ ba?", p:"Không. Dừng Teapot, giữ Pivot 1 và lịch mức B; T3 và C1–C4 vào bài như phân tích exploratory về điều kiện cần của một field test, không phải claim.", n:"T0: chỉ 4 bảng TD, tối đa 2 giếng độc lập (cần ≥ 3 cho C3 cộng 11–18 cho C4). Pilot P-a (knot horizon–top, 37 giếng dev, chưa mở porosity): σ̂_knot 6,75 ms (CI 90% 4,1–9,4) so với dung sai 1,5 ms. Người dùng chốt: quay về lịch mức B."},
{id:"D-12", q:"Bản thảo dài hơn giới hạn của venue", p:"Bỏ lượt rút gọn độ dài cho venue. Rủi ro độ dài vẫn ghi lại (plan R9), chưa có biện pháp.", n:"Thân bài khoảng 14.750 từ (đếm thô sau A6); giới hạn Research Article khoảng 5.500 từ theo nguồn thứ cấp (trang chính thức không tải được). Agent đã đề xuất rút gọn ngày 30–31/10 (chứng minh, Thí nghiệm 1, H1 và Phụ lục B sang Supplementary); người dùng bỏ phương án này ngày 29/10 (plan §12 ý 25). Người dùng chốt."} {id:"D-12", q:"Bản thảo dài hơn giới hạn của venue", p:"Bỏ lượt rút gọn độ dài cho venue. Rủi ro độ dài vẫn ghi lại (plan R9), chưa có biện pháp.", n:"Thân bài khoảng 14.750 từ (đếm thô sau A6); giới hạn Research Article khoảng 5.500 từ theo nguồn thứ cấp (trang chính thức không tải được). Agent đã đề xuất rút gọn ngày 30–31/10 (chứng minh, Thí nghiệm 1, H1 và Phụ lục B sang Supplementary); người dùng bỏ phương án này ngày 29/10 (plan §12 ý 25). Người dùng chốt."},
{id:"D-13", q:"Code tổng hợp đã khoá của protocol_bench khác lời phát biểu ở ba verdict", p:"Phán quyết theo lời phát biểu: S1-H1 lấy hai ô N ∈ {4, 16}; S2-H1 một verdict mỗi trục; S3-H1 đối thủ là {B3b, B3c, B3c-R, B4a–d}, không có Ctl-GP. Tính ở scripts/36_bench_verdicts.py (ngoài lock); không sửa code đã khoá; báo cáo cả hai cách đọc và ghi là deviation thực thi trong Methods.", n:"Phát hiện ngày 02/11, sau chạy chính và trước khi bài dùng số. Chỉ S3-H1 đổi kết luận: theo code không đạt ở mọi regime vì Ctl-GP (bank nhiễu GP cùng hai moment của posterior) gần trùng B3d-Sa; theo phát biểu đạt ở R10, R0, Rm5. S1-H1: code trả null vì S1 có 4 giá trị N. S2-H1: code tính đúng từng trục, chỉ summary.md in sai. Agent chốt theo bằng chứng."},
{id:"D-14", q:"Lời phát biểu đã khoá của S8-H2 gọi BK2 là 'calibrated bank'", p:"Giữ verdict, sửa cách diễn đạt trong bài: 'calibrated' ở đây chỉ nghĩa yếu (warp thật là một thành viên). Bài ghi rõ BK2 không phải bank hiệu chỉnh theo Mệnh đề 4, và đối chiếu transfer đo được với cos²(πfΔ) của Hệ quả 3 (a). Đây là post hoc, không phải verdict (scripts/38_bench_figures.py --flipband).", n:"02/11, khi viết Sec. 6.5 (plan §12 ý 30). Không sửa protocol đã khoá. Trong băng đảo dấu ở N = 16, BK2 có transfer 0,92–1,00, trong khi trung bình cos² là 0,05–0,59: BK2 làm tốt hơn trung bình hai thành viên của nó, khớp với tái đăng ký (Remark 1). Agent chốt theo bằng chứng."}
]; ];
const FINDS = [ const FINDS = [
@@ -392,10 +415,12 @@ const FINDS = [
{h:"Tie trung bình posterior làm sắc, không làm mờ", p:"Mệnh đề 3 của bài: sai số classical (độc lập với nhãn thật) làm mờ predictor và nới phương sai học được; sai số <b>Berkson</b> (độc lập với dữ liệu, như tie trung bình posterior) làm sắc và thu hẹp. Bank hiệu chỉnh có cùng nghiệm quần thể với nhãn thật (Mệnh đề 4), nhưng lợi ích quần thể so với nhãn điểm chỉ là <b>bậc bốn</b> theo σ. Cận 1/B(σ_post) dùng cho H2b là ρ* dưới cấu trúc classical. Dưới Berkson, cận thấp hơn nhiều. Hệ số e^{4π²σ²f²} giữa hai tích phân là 1,10 ở 25 Hz nhưng 1,77 ở 60 Hz (σ = 2 ms), và méo có trọng số f⁴ nằm ở 67–72 Hz. Ở σ = 2 ms, tích phân Berkson vì thế gấp <b>2,1–2,6</b> lần. Nhận định trước đó \"hệ số dưới 1,17, cấu trúc gần như không đổi cận\" sai (chỉ xét ≤ 25 Hz) và đã được sửa ngày 29/10."}, {h:"Tie trung bình posterior làm sắc, không làm mờ", p:"Mệnh đề 3 của bài: sai số classical (độc lập với nhãn thật) làm mờ predictor và nới phương sai học được; sai số <b>Berkson</b> (độc lập với dữ liệu, như tie trung bình posterior) làm sắc và thu hẹp. Bank hiệu chỉnh có cùng nghiệm quần thể với nhãn thật (Mệnh đề 4), nhưng lợi ích quần thể so với nhãn điểm chỉ là <b>bậc bốn</b> theo σ. Cận 1/B(σ_post) dùng cho H2b là ρ* dưới cấu trúc classical. Dưới Berkson, cận thấp hơn nhiều. Hệ số e^{4π²σ²f²} giữa hai tích phân là 1,10 ở 25 Hz nhưng 1,77 ở 60 Hz (σ = 2 ms), và méo có trọng số f⁴ nằm ở 67–72 Hz. Ở σ = 2 ms, tích phân Berkson vì thế gấp <b>2,1–2,6</b> lần. Nhận định trước đó \"hệ số dưới 1,17, cấu trúc gần như không đổi cận\" sai (chỉ xét ≤ 25 Hz) và đã được sửa ngày 29/10."},
{h:"Lợi ích của bank: vượt cận classical, phần lớn trong cận Berkson (post hoc)", p:"scripts/31_p2r_posthoc.py, 8 ô rộng ở N = 16. Với cận classical đã đăng ký, M2-Sa/B3d-Sa thấp hơn cận ở <b>7/8</b> ô khi tính tại σ_post và <b>6/8</b> khi tính tại sai số warp RMS. R10tb c = 2 vượt mép lưới blur 6 ms, nên cận bị kẹp ở 1/B(6 ms) = 0,634; tính đúng tại σ_post là 0,481. Cận Berkson, cấu trúc tự nhiên cho nhãn tại warp trung bình, được tính post hoc. Với cận này chỉ <b>3/8</b> ô vượt tại σ_post (R0, R0h, R10tb ở c = 1; hai ô sau lề < 0,004), và tối đa 1/8 tại sai số warp. Hai biến thể (giữ hệ số ở 60 Hz; phổ chéo) cho cùng kết quả. Nhận định \"vượt cận\" ghi trước đó đã bị rút lại; chưa kiểm sai số thật có kiểu Berkson không (T2 test iv). M2-Sa không đạt Oracle ở ô rộng nào (kém 4–6% ở R0, R0h, Rm5 với c = 1; 17% ở R10tb c = 1; 63% ở R10tb c = 2) và chỉ đóng 27–46% khoảng cách tới Oracle ở c = 1, 39–65% ở c = 2. Nguồn lợi ích còn mở (T2)."}, {h:"Lợi ích của bank: vượt cận classical, phần lớn trong cận Berkson (post hoc)", p:"scripts/31_p2r_posthoc.py, 8 ô rộng ở N = 16. Với cận classical đã đăng ký, M2-Sa/B3d-Sa thấp hơn cận ở <b>7/8</b> ô khi tính tại σ_post và <b>6/8</b> khi tính tại sai số warp RMS. R10tb c = 2 vượt mép lưới blur 6 ms, nên cận bị kẹp ở 1/B(6 ms) = 0,634; tính đúng tại σ_post là 0,481. Cận Berkson, cấu trúc tự nhiên cho nhãn tại warp trung bình, được tính post hoc. Với cận này chỉ <b>3/8</b> ô vượt tại σ_post (R0, R0h, R10tb ở c = 1; hai ô sau lề < 0,004), và tối đa 1/8 tại sai số warp. Hai biến thể (giữ hệ số ở 60 Hz; phổ chéo) cho cùng kết quả. Nhận định \"vượt cận\" ghi trước đó đã bị rút lại; chưa kiểm sai số thật có kiểu Berkson không (T2 test iv). M2-Sa không đạt Oracle ở ô rộng nào (kém 4–6% ở R0, R0h, Rm5 với c = 1; 17% ở R10tb c = 1; 63% ở R10tb c = 2) và chỉ đóng 27–46% khoảng cách tới Oracle ở c = 1, 39–65% ở c = 2. Nguồn lợi ích còn mở (T2)."},
{h:"Coverage: độ dài huấn luyện lẫn với nguồn nhãn (T4, post hoc)", p:"Mọi ensemble quá hẹp: tỉ số ξ = E s²/E(y − μ)² chỉ <b>0,19</b> ở Oracle và tối đa 0,66 (B5) ở R10, c = 1, N = 16. B3c-R học 500 vòng lặp như Oracle và đạt cùng ξ với B3d-Sa ở 250 vòng. Trên dev, coverage90 của Oracle đơn lẻ giảm 0,47 → 0,23 → 0,10 sau 125/500/2000 vòng. Phần (b), (c) của Mệnh đề 5 chưa kiểm; không claim hiệu chỉnh."}, {h:"Coverage: độ dài huấn luyện lẫn với nguồn nhãn (T4, post hoc)", p:"Mọi ensemble quá hẹp: tỉ số ξ = E s²/E(y − μ)² chỉ <b>0,19</b> ở Oracle và tối đa 0,66 (B5) ở R10, c = 1, N = 16. B3c-R học 500 vòng lặp như Oracle và đạt cùng ξ với B3d-Sa ở 250 vòng. Trên dev, coverage90 của Oracle đơn lẻ giảm 0,47 → 0,23 → 0,10 sau 125/500/2000 vòng. Phần (b), (c) của Mệnh đề 5 chưa kiểm; không claim hiệu chỉnh."},
{h:"Reference ở giếng blind phải chính xác cỡ 1 ms (T3, exploratory)", p:"Chấm lại dự đoán P2r với reference lệch σ_ref: tỉ số band RMSE trung vị cắt 1 ở <b>3,6–4,3 ms</b> (Hệ quả 4 dự báo σ/√2 = 3,0/4,1/5,1 ms). Sign test α = 0,05 cần 5–18 giếng blind nếu reference chính xác (5/6 ô), 11–30 giếng ở 1 ms (4 ô); ở 2 ms chỉ R0 còn trong 40 giếng; từ 3 ms không ô nào. Luật k-of-n của G-C, G-D không phải phép kiểm: đạt ngẫu nhiên với xác suất 0,31 (n = 4) và 0,11 (n = 6)."}, {h:"Reference ở giếng blind phải chính xác cỡ 1 ms (T3, exploratory)", p:"Chấm lại dự đoán P2r với reference lệch σ_ref: tỉ số band RMSE trung vị cắt 1 ở <b>3,6–4,3 ms</b> (Hệ quả 4, sửa 02/11: không có shrinkage thì điểm cắt nằm dưới σ/√2 = 3,0/4,1/5,1 ms, và bằng σ/√2 ở bậc đầu; điều kiện này cần nhưng không đủ; R10 cao hơn 0,6 ms, điều shrinkage cho phép). Sign test α = 0,05 cần 5–18 giếng blind nếu reference chính xác (5/6 ô), 11–30 giếng ở 1 ms (4 ô); ở 2 ms chỉ R0 còn trong 40 giếng; từ 3 ms không ô nào. Luật k-of-n của G-C, G-D không phải phép kiểm: đạt ngẫu nhiên với xác suất 0,31 (n = 4) và 0,11 (n = 6)."},
{h:"F3 và Volve trượt điều kiện C1; Teapot không có reference TD độc lập", p:"Hồi cứu (scripts/26): band PCC ở giếng blind 0,15 (F3) và 0,13/0,04 (Volve), dưới ngưỡng 0,47 suy từ D2; cả hai đạt C2 (σ_post trung vị 2,8 và 4,3 ms). Teapot Dome: 152 giếng có density trong survey 3-D nhưng tối đa <b>2</b> giếng có TD độc lập; knot horizon–top cho σ̂_knot <b>6,75 ms</b> (CI 90% 4,1–9,4) so với dung sai 1,5 ms (D-11)."}, {h:"F3 và Volve trượt điều kiện C1; Teapot không có reference TD độc lập", p:"Hồi cứu (scripts/26): band PCC ở giếng blind 0,15 (F3) và 0,13/0,04 (Volve), dưới ngưỡng 0,47 suy từ D2; cả hai đạt C2 (σ_post trung vị 2,8 và 4,3 ms). Teapot Dome: 152 giếng có density trong survey 3-D nhưng tối đa <b>2</b> giếng có TD độc lập; knot horizon–top cho σ̂_knot <b>6,75 ms</b> (CI 90% 4,1–9,4) so với dung sai 1,5 ms (D-11)."},
{h:"Bản thảo dài gấp khoảng 2,7 lần giới hạn của venue", p:"Thân bài (mục 1–8) khoảng <b>14.750</b> từ (đếm thô sau A6); giới hạn Research Article của Computers & Geosciences khoảng 5.500 từ theo nguồn thứ cấp, chưa kiểm trên trang chính thức. Người dùng bỏ lượt rút gọn (D-12); rủi ro vẫn mở."}, {h:"Bản thảo dài gấp khoảng 3,3 lần giới hạn của venue", p:"Thân bài (mục 1–8) khoảng <b>18.100</b> từ (đếm thô sau lượt viết kết quả ngày 02/11; sau A6 là 14.750; lượt rà chứng minh cùng ngày thêm khoảng 350 từ, lượt đọc toàn văn Sec. 2 thêm khoảng 130 từ, ước tính), 68 trang; giới hạn Research Article của Computers & Geosciences khoảng 5.500 từ theo nguồn thứ cấp, chưa kiểm trên trang chính thức. Người dùng bỏ lượt rút gọn (D-12); rủi ro vẫn mở."},
{h:"T2: lợi ích bank ở c = 1 chủ yếu là tăng cường nhãn, không phải thông tin của posterior", p:"Exploratory, khai báo trước. Sai số nhãn của B3d-Sa là <b>Berkson</b> ở c = 1, nên cận áp dụng là 1/B_b và lợi ích H2b không vượt hiệu chỉnh quần thể. Một bank nhiễu GP có cùng trung bình và hiệp phương sai với posterior (không thêm thông tin) đạt phần lớn lợi ích ở c = 1; bank SMC chỉ hơn rõ ở c = 2. RML có tái định vị ngầm (warp trọng số responsibility tốt hơn 13–40 % ở 8/8 ô rộng). Khoảng một phần ba khoảng cách PM–Oracle là độ dài huấn luyện."} {h:"T2: lợi ích bank ở c = 1 chủ yếu là tăng cường nhãn, không phải thông tin của posterior", p:"Exploratory, khai báo trước. Sai số nhãn của B3d-Sa là <b>Berkson</b> ở c = 1, nên cận áp dụng là 1/B_b và lợi ích H2b không vượt hiệu chỉnh quần thể. Một bank nhiễu GP có cùng trung bình và hiệp phương sai với posterior (không thêm thông tin) đạt phần lớn lợi ích ở c = 1; bank SMC chỉ hơn rõ ở c = 2. RML có tái định vị ngầm (warp trọng số responsibility tốt hơn 13–40 % ở 8/8 ô rộng). Khoảng một phần ba khoảng cách PM–Oracle là độ dài huấn luyện."},
{h:"P6: nhãn trung bình posterior đứng vững trước c = 1,5, backbone TCN và baseline B4, nhưng không trước sai pha wavelet", p:"protocol_bench, realization 8–15, R10. B3d-Sa hơn tie điểm tốt nhất ở c = 1,5 (<b>0,853 / 0,796</b> ở N = 4/16), với TCN ở c = 1 (0,840 / 0,823) và khi thêm B4a–d làm đối thủ (B4 không là đối thủ tốt nhất ở ô c ≤ 1 nào). Dưới sai mô hình mức L1: drift giữ lợi ích (0,862 / 0,798); rock physics thu hẹp xuống dưới ngưỡng (0,940 / 0,934); sai pha wavelet xoá hẳn (1,023 / 1,042 so với B3c) vì posterior SMC quá tự tin (cov90 0,17 / 0,10; warp RMSE 2,6 / 2,3 ms so với σ_post 0,7 ms). Dự đoán trước là đạt cho cả rock physics và wavelet."},
{h:"P6: bank hai mode sửa nhãn trung bình khi các mode tách được (S8)", p:"Posterior hai mode dựng từ warp thật. Ở Δ = 32 ms, R10, hàm truyền của nhãn trung bình (PM2) so với Oracle âm trong băng đảo dấu (<b>−0,70 / −0,49</b>), đúng Hệ quả 3. Bank hai thành viên (BK2) có band RMSE bằng 0,28–0,71 lần PM2 ở Δ ∈ {16, 32} ms; ở Δ = 8 ms (mô tả) 0,60–0,98. BK2 không phải bank hiệu chỉnh theo Mệnh đề 4: khi λ → 0, Hệ quả 3 cho transfer cos²(πfΔ), trung bình 0,05–0,59 trong băng đảo dấu, nhưng đo được 0,92–1,00 ở N = 16 (post hoc). Điều này khớp với tái đăng ký qua responsibility. S1-H2: lợi ích bank tăng theo N ở 13/13 họ rộng, ρ = −0,47."}
]; ];
const DATA = [ const DATA = [
@@ -541,7 +566,7 @@ const LOG = [
["2026-10-29","Đồng bộ tài liệu (A6): plan §0, §6, §6.1, §8, §9 (R9), §12 ý 23–24; AGENTS.md; README.md (scripts 26–31); paper/README.md (nguồn số liệu theo mục mới); docs/theory.md mục 6 và ghi chú sửa mục 1.4; tài liệu pivot. Chưa commit."], ["2026-10-29","Đồng bộ tài liệu (A6): plan §0, §6, §6.1, §8, §9 (R9), §12 ý 23–24; AGENTS.md; README.md (scripts 26–31); paper/README.md (nguồn số liệu theo mục mới); docs/theory.md mục 6 và ghi chú sửa mục 1.4; tài liệu pivot. Chưa commit."],
["2026-10-29","Tự sửa hai nhận định của chính mình (plan §12 ý 24). (1) Câu \"hai cấu trúc sai số gần như cho cùng cận (hệ số < 1,17)\" sai: méo nằm ở 67–72 Hz, nơi tích phân Berkson gấp 1,5–4,6 lần ở σ = 1,5–2,5 ms. (2) Câu \"lợi ích của bank vượt cận quần thể\" chỉ đúng với cận classical đã đăng ký (7/8 ô). Với cận Berkson tính post hoc, chỉ 3/8 ô vượt (cả ba ở c = 1) và tối đa 1/8 tại sai số warp. scripts/31 viết lại để tính cận (a), (b), b60 và phổ chéo (đọc npz của Oracle, khoảng 6 phút; tái lập đúng số đã đăng ký). Đã sửa bài mục 4.3, 6.3 (cột 1/B_b ở Bảng tab:h2b), 6.4, 7, tóm tắt, mở bài, kết luận, cùng tài liệu. Câu hỏi của T2 đổi thành: còn lợi ích nào vượt hiệu chỉnh Berkson không. Bài build sạch, 55 trang; thân bài khoảng 14.750 từ (đếm thô), tóm tắt 292 từ. Chưa commit."], ["2026-10-29","Tự sửa hai nhận định của chính mình (plan §12 ý 24). (1) Câu \"hai cấu trúc sai số gần như cho cùng cận (hệ số < 1,17)\" sai: méo nằm ở 67–72 Hz, nơi tích phân Berkson gấp 1,5–4,6 lần ở σ = 1,5–2,5 ms. (2) Câu \"lợi ích của bank vượt cận quần thể\" chỉ đúng với cận classical đã đăng ký (7/8 ô). Với cận Berkson tính post hoc, chỉ 3/8 ô vượt (cả ba ở c = 1) và tối đa 1/8 tại sai số warp. scripts/31 viết lại để tính cận (a), (b), b60 và phổ chéo (đọc npz của Oracle, khoảng 6 phút; tái lập đúng số đã đăng ký). Đã sửa bài mục 4.3, 6.3 (cột 1/B_b ở Bảng tab:h2b), 6.4, 7, tóm tắt, mở bài, kết luận, cùng tài liệu. Câu hỏi của T2 đổi thành: còn lợi ích nào vượt hiệu chỉnh Berkson không. Bài build sạch, 55 trang; thân bài khoảng 14.750 từ (đếm thô), tóm tắt 292 từ. Chưa commit."],
["2026-10-29","Người dùng bỏ lượt rút gọn độ dài cho venue (D-12, plan §12 ý 25). Thẻ p5-len thay bằng p5-cite (trích dẫn dataset F3, Volve; 30–31/10). Rủi ro độ dài (R9) vẫn ghi lại, chưa có biện pháp."], ["2026-10-29","Người dùng bỏ lượt rút gọn độ dài cho venue (D-12, plan §12 ý 25). Thẻ p5-len thay bằng p5-cite (trích dẫn dataset F3, Volve; 30–31/10). Rủi ro độ dài (R9) vẫn ghi lại, chưa có biện pháp."],
["2026-10-29","Commit và push lên main mọi thay đổi từ P4 đến A6 (code P4, configs/protocol_volve.*, scripts 26–31, docs/research, bản ghi P4x, bài và tài liệu), kèm tag protocol-volve. Hash code tính lại từ cây commit khớp configs/protocol_volve.lock.json. 190 test pass, 1 skip. logs/*.out vẫn không theo dõi như trước (plan §12 ý 25)."] ["2026-10-29","Commit và push lên main mọi thay đổi từ P4 đến A6 (code P4, configs/protocol_volve.*, scripts 26–31, docs/research, bản ghi P4x, bài và tài liệu), kèm tag protocol-volve. Hash code tính lại từ cây commit khớp configs/protocol_volve.lock.json. 190 test pass, 1 skip. logs/*.out vẫn không theo dõi như trước (plan §12 ý 25)."],
["2026-10-29","P6 bắt đầu sớm. p6-gen xong (misspec cho generator D2, đường mặc định tái lập P2r từng bit, 15 test mới). T2 đã khai báo trước và đang chạy trên hai GPU. Bắt đầu dựng runner benchmark và nháp protocol_bench (chưa khoá). Từ 13:00 UTC một project khác giữ khoảng 125–128 GB mỗi H200, nên chỉ còn vài GB trống; không mở thêm worker."], ["2026-10-29","P6 bắt đầu sớm. p6-gen xong (misspec cho generator D2, đường mặc định tái lập P2r từng bit, 15 test mới). T2 đã khai báo trước và đang chạy trên hai GPU. Bắt đầu dựng runner benchmark và nháp protocol_bench (chưa khoá). Từ 13:00 UTC một project khác giữ khoảng 125–128 GB mỗi H200, nên chỉ còn vài GB trống; không mở thêm worker."],
["2026-10-29","T2 xong (exploratory, 12:39–13:27 UTC, hai GPU, không OOM): Berkson ở c = 1, cận 1/B_b áp dụng; bank nhiễu GP đạt phần lớn lợi ích c = 1; tái định vị ngầm có thật; không có bằng chứng cho cơ chế đa mode; một phần ba khoảng PM–Oracle là độ dài huấn luyện. Kết quả T2 không dùng để chọn lại budget."], ["2026-10-29","T2 xong (exploratory, 12:39–13:27 UTC, hai GPU, không OOM): Berkson ở c = 1, cận 1/B_b áp dụng; bank nhiễu GP đạt phần lớn lợi ích c = 1; tái định vị ngầm có thật; không có bằng chứng cho cơ chế đa mode; một phần ba khoảng PM–Oracle là độ dài huấn luyện. Kết quả T2 không dùng để chọn lại budget."],
["2026-10-29","Runner benchmark xong; tái lập ô P2r qua runner mới khớp từng bit. Mức misspec S2 chốt trên dev 902–905. Nháp protocol_bench đã rà soát; sửa các chỗ không nhất quán rồi khoá sau khi chọn budget TCN trên dev."], ["2026-10-29","Runner benchmark xong; tái lập ô P2r qua runner mới khớp từng bit. Mức misspec S2 chốt trên dev 902–905. Nháp protocol_bench đã rà soát; sửa các chỗ không nhất quán rồi khoá sau khi chọn budget TCN trên dev."],
@@ -552,7 +577,16 @@ const LOG = [
["2026-10-30","Lượt viết theo skill research-paper-writing (Master-cai/Research-Paper-Writing-Skills, cài ở ~/.claude/skills): câu chủ đề, tách đoạn nhiều ý, thuật ngữ (P2/P2r → Experiment 1/2 trong Sec. 5), hạ claim chưa đủ bằng chứng (H1 chỉ khớp 1% ở 4–16 ms; phần lớn lợi ích H2a có sẵn ở c = 0; H2b 8/8 chỉ ở N = 16). Không đổi số đăng ký, trích dẫn hay TODO đỏ nào; main.pdf 56 trang. Tự review: paper/self_review.md."], ["2026-10-30","Lượt viết theo skill research-paper-writing (Master-cai/Research-Paper-Writing-Skills, cài ở ~/.claude/skills): câu chủ đề, tách đoạn nhiều ý, thuật ngữ (P2/P2r → Experiment 1/2 trong Sec. 5), hạ claim chưa đủ bằng chứng (H1 chỉ khớp 1% ở 4–16 ms; phần lớn lợi ích H2a có sẵn ở c = 0; H2b 8/8 chỉ ở N = 16). Không đổi số đăng ký, trích dẫn hay TODO đỏ nào; main.pdf 56 trang. Tự review: paper/self_review.md."],
["2026-10-30","01:02 UTC: người dùng báo server sắp bị thu hồi; tách S1 nhóm B thành hai driver (R0h cuda:0, R10tb cuda:1, mỗi driver 14 worker), nhóm A 8 worker, tổng 36 worker. S2 đã xong 00:12, S3+S4+S8 xong 00:58 UTC."], ["2026-10-30","01:02 UTC: người dùng báo server sắp bị thu hồi; tách S1 nhóm B thành hai driver (R0h cuda:0, R10tb cuda:1, mỗi driver 14 worker), nhóm A 8 worker, tổng 36 worker. S2 đã xong 00:12, S3+S4+S8 xong 00:58 UTC."],
["2026-10-30","02:16 UTC: xong toàn bộ chạy chính P6 (S1 560, S2 224 + 224, S3+S4+S8 384). Dừng supervisor. Bước tiếp theo: summarize, chưa chạy."], ["2026-10-30","02:16 UTC: xong toàn bộ chạy chính P6 (S1 560, S2 224 + 224, S3+S4+S8 384). Dừng supervisor. Bước tiếp theo: summarize, chưa chạy."],
["2026-10-30","Chuyển server: sync nguyên thư mục; git chỉ chứa code/docs. Khoảng 600 MB output lỡ push lúc 01:05–01:15 UTC đã bị gỡ bằng viết lại lịch sử và force-push theo yêu cầu (main = 381b5ff). Danh sách file ngoài git và sha256: docs/research/server-migration.md, docs/research/unpushed_outputs.sha256."] ["2026-10-30","Chuyển server: sync nguyên thư mục; git chỉ chứa code/docs. Khoảng 600 MB output lỡ push lúc 01:05–01:15 UTC đã bị gỡ bằng viết lại lịch sử và force-push theo yêu cầu (main = 381b5ff). Danh sách file ngoài git và sha256: docs/research/server-migration.md, docs/research/unpushed_outputs.sha256."],
["2026-11-02","Sửa lộ trình (Gantt) không hiện: thiếu dấu phẩy sau một mục của mảng LOG làm renderStatic() lỗi trước khi vẽ. Summarize P6 bằng code đã khoá (02:02 UTC; lock khớp, 8.799 file khớp sha256). scripts/36_bench_verdicts.py đọc lại 11 verdict đúng lời phát biểu: 9 đạt; S2-H1 không đạt ở rock physics và wavelet (dự đoán là đạt), đạt ở drift. S3-H1 đạt theo phát biểu ở R10, R0, Rm5, không đạt theo code vì code đưa Ctl-GP vào đối thủ (D-13). Bước tiếp theo: S7 đóng gói, viết lại mục kết quả."],
["2026-11-02","S7 đóng gói benchmark xong, trừ bước deposit Zenodo: scripts/37_bench_package.py (generate, check, tables, score, selftest; ngoài lock). 630 task (test 8–15, dev 900–905), 1.260 file, 845 MB trong outputs/bench/package/; chạy lại tái lập 1.260/1.260 hash nội dung (benchmark/MANIFEST.json). 45.200 run tham chiếu → benchmark/reference/. Selftest đạt (metric và luật khớp run tham chiếu). benchmark/README.md, benchmark/zenodo_metadata.json (nháp; chưa upload). Bước tiếp theo: viết lại các mục kết quả."],
["2026-11-02","Viết xong các mục kết quả và thêm trích dẫn dataset (plan §12 ý 30). Sec. 6.5 mới, Thí nghiệm 3: bảng thiết kế, bảng 11 verdict với cả hai cách đọc, S1 (hình), S2 (bảng; trượt ở rock physics và pha wavelet), S3, S4, S8 (bảng, hình), nhánh cùng budget. Sec. 6.4 (T2) thay todoblock. Sửa thêm Sec. 3.2, 5, abstract, intro, discussion, kết luận và availability; bỏ TODO ở tiêu đề. refs.bib thêm dgb2023f3demo, equinor2018volve. scripts/38_bench_figures.py vẽ hình, --flipband in bảng cos/cos² của S8 (D-14). tab:methods đổi sang [!tbp] vì bảng cao quá giới hạn của [t] khiến mọi bảng sau bị dồn về cuối. Bài 66 trang, biên dịch sạch; thân bài khoảng 18.100 từ (R9). Bước tiếp theo: review nội bộ và nộp; deposit Zenodo cần người dùng."],
["2026-11-02","Quét novelty sơ bộ cho todoblock Sec. 2 (plan §12 ý 31): Crossref, OpenAlex 2025–2026 (8 truy vấn) và web search. Không bài nào đưa posterior hay bất định của tie vào huấn luyện mô hình dự đoán thuộc tính; câu 'to our knowledge' giữ nguyên. Thêm, chỉ đọc abstract: Herrera & van der Baan 2014 (Geophysics, bản xuất bản của preprint 2012 đã đọc), Autotie (da Costa Silva et al., Geophysics 2026; thêm vào bảng positioning), Castagna, Kronberg & Gil (TLE 2026, độ đo chất lượng tie và dự đoán). Đọc lại toàn văn Sukar 2026 trong refs/: huấn luyện trên bản đồ 4D tổng hợp sinh từ mô hình mô phỏng, nhãn không qua well tie, nên cột UQ→train = -- là công bằng; Sec. 2 ghi rõ điều này. Còn mở cho ngày 13/11: abstract IMAGE 2026 của Palavicini Gurria (chưa được index), DOI của Quesada 2024. Todoblock rút gọn; bài 66 trang, biên dịch sạch."],
["2026-11-02","Kiểm tra bản toàn văn của các bài chỉ đọc abstract (OpenAlex, Unpaywall, web search). Tải được rizzuti2024waveletflows và rizzuti2025uhr (bản Shearwater đăng công khai) vào refs/; toàn văn khớp với cách xếp trong Bảng tab:positioning, chú thích ᵃ chưa bỏ. Các bài khác không có bản mở; castagna2026quality được Unpaywall báo là OA nhưng cần tải tay (refs/MISSING.md)."],
["2026-11-02","Rà phụ lục chứng minh và dựng gói tái lập (plan §12 ý 32). Chứng minh: 15 điểm từ một lượt đọc độc lập, sửa 14, sửa một phần 1 (Sec. 4, App. A, Bổ đề 5, abstract, Sec. 6.3, 6.6, docs/theory.md, docstring scripts/38); không đổi verdict hay số đã báo cáo; bài 67 trang, không warning. Gói tái lập: scripts/39_repro_package.py, repro/{README.md, MANIFEST.json, requirements-linux.txt, verify_report.md}; 5 archive theo giấy phép trong outputs/repro/ (chưa deposit); phòng sạch không có dữ liệu thô: 12/12 bước tái tạo đúng (63 file trùng byte, 3 trùng giá trị, 0 khác; không đọc ngoài phòng sạch), tests/test_d2_misspec.py qua 15/15. Sec. 8 thêm câu về các archive dữ liệu dẫn xuất (TODO DOI)."],
["2026-11-02","Đọc toàn văn bốn bài người dùng tải tay (AWSM, BootNet, P05 Li–Grana–Liu 2024, Guillon 2020; đổi tên theo key BibTeX trong refs/). Cách xếp trong Bảng tab:positioning không đổi; câu 'to our knowledge' giữ nguyên. AWSM: 44 giếng, giữ mô hình median/minimum-misfit, posterior TD chỉ báo cáo. Sửa Sec. 2 theo toàn văn, bỏ chú thích ᵃ của sáu bài (cả hai bài Rizzuti), cập nhật annote trong refs.bib. Bài biên dịch sạch, 68 trang (plan §12 ý 33)."],
["2026-11-02","Đóng việc tìm toàn văn (quyết định của người dùng): các bài còn chỉ có abstract giữ chú thích ᵃ; todoblock (2) Sec. 2 ghi là đã đóng. Còn castagna2026quality (CC BY) chờ người dùng tải tay tại doi.org/10.1190/tle-2025-1058 (plan §12 ý 33)."],
["2026-11-02","Đọc toàn văn castagna2026quality (người dùng tải tay; refs/castagna2026quality.pdf). Câu cũ ở Sec. 2 ('abstract không bàn sai số thời gian') sai: phần Discussion nói hàm time–depth không bao giờ chính xác và time shift làm hỏng chủ yếu tần số cao; các độ đo theo phân bố không nhạy với dịch nhỏ; sai số thời gian không được mô hình hóa hay đưa vào huấn luyện. Đã viết lại câu; 'to our knowledge' giữ nguyên; bài 68 trang. Việc tìm toàn văn đóng (plan §12 ý 33)."]
]; ];
/* ===================== HẾT DATA ===================== */ /* ===================== HẾT DATA ===================== */

77838
repro/MANIFEST.json Normal file

File diff suppressed because it is too large Load Diff

196
repro/README.md Normal file
View File

@@ -0,0 +1,196 @@
# Reproduction package
This directory documents how to reproduce the numbers, tables and figures of the manuscript *Label registration
error in sparse-well seismic property learning: theory, a registration-aware benchmark, and the limits of field
validation*. The package has four parts:
| part | where | what |
|---|---|---|
| code and locked protocols | this git repository (archive: `scripts/39_repro_package.py code --rev <commit>`) | `ml_porosity/`, `scripts/`, `operations/`, `tests/`, `configs/` (six locked protocols with `.sha256` and, from P3 on, `.lock.json`), `paper/` |
| derived data | five `tar.gz` archives, hashed in [`MANIFEST.json`](MANIFEST.json) | every output file that a number of the manuscript is computed from, split by data licence |
| benchmark package | separate deposit, documented in [`../benchmark/README.md`](../benchmark/README.md) | 630 synthetic tasks with hidden truth, 45,200 reference runs, a scorer |
| clean-room check | [`verify_report.md`](verify_report.md) | the summary, post hoc, table and figure stages rerun from the code and the archives only |
Archive DOI: TODO (not deposited yet). Code licence: TODO (to be chosen by the authors).
## 1. Derived-data archives and licences
Each archive stores its members as `outputs/<path>`. Extract every archive in the repository root to restore the
`outputs/` tree that the scripts read, then check it:
```bash
for a in ML-Porosity_derived_*.tar.gz; do tar -xzf "$a"; done
.venv/bin/python scripts/39_repro_package.py check --root . # sha256 of all 11,112 files against MANIFEST.json
```
| archive | files | size (unpacked / packed) | licence | content |
|---|---|---|---|---|
| `ML-Porosity_derived_f3_results.tar.gz` | 9,044 | 431 MB / 164 MB | CC BY-SA 3.0 | summaries, verdicts, post hoc tables, run-level metric tables, posterior summaries, and the small derived inputs (F3 well file, tie QC, wavelets, warp prior, D2 horizon cache) |
| `ML-Porosity_derived_f3_predictions.tar.gz` | 1,950 | 2.13 GB / 2.11 GB | CC BY-SA 3.0 | saved test predictions of the registered runs (P1, P2, P2r, T2, protocol_bench, P3), and the P2r SMC particles of the S4 cells, which the protocol_bench lock hashes |
| `ML-Porosity_derived_f3_volume.tar.gz` | 10 | 627 MB / 505 MB | CC BY-SA 3.0 | descriptive F3 porosity volume of the 20 P3 deployment models (649 interior inlines) |
| `ML-Porosity_derived_volve.tar.gz` | 97 | 10.6 MB / 8.9 MB | CC BY-NC-SA 4.0 | Volve well data on seismic time, P4 summaries, post hoc tables, and the applicability tables (F3 and Volve) |
| `ML-Porosity_derived_teapot.tar.gz` | 11 | 0.6 MB / 0.1 MB | CC0 1.0 (to be verified) | Teapot Dome inventory (headers and curve coverage) and pilot P-a (knots, picks); no porosity |
`MANIFEST.json` lists, for each file, its archive, the script that produced it, its size and the sha256 of its
exact bytes. The archives are deterministic: `scripts/39_repro_package.py build` writes the same bytes from the same
`outputs/` tree (sorted members, fixed mtime and owner, gzip mtime 0).
Files left out of the archives: training checkpoints, the large SMC particle files (except those of the S4 cells),
smoke runs, superseded backups, `outputs/p4x/` (dropped exploratory study, never used in the manuscript), the
quick-look PNGs under `outputs/figures/` and the benchmark package `outputs/bench/package/` (deposited separately).
Licence notes for the authors (to settle before deposit):
- **F3.** The F3 Demo 2023 data are distributed by dGB Earth Sciences (TerraNubis) under CC BY-SA 3.0. The synthetic
D2 data use the F3 survey geometry, horizons, wavelet and warp prior, so their outputs are treated as F3-derived.
The repository itself tracks 102 F3 well files under `data/F3_Demo_2023/` (logs, checkshots, markers, the
`.survey` file); they are redistributed under the same licence.
- **Volve.** The licence files of the Volve release name CC BY-NC-SA 4.0. The data owners are Equinor,
ExxonMobil, Bayerngas and the Norwegian Petroleum Directorate.
- **F3 and Volve combined.** `outputs/applicability/` tabulates statistics of both fields. It is placed in the Volve
archive under the more restrictive licence. CC BY-SA 3.0 requires adaptations to carry a compatible
share-alike licence, and CC BY-NC-SA 4.0 is not one, so the authors should confirm that these tables of summary
statistics can be shared this way, or split them by field.
- **Teapot Dome.** Recorded as CC0 in the project notes (Texas Data Repository, doi:10.18738/T8/21WDU8); verify on
the repository page.
- **NLOG.** `outputs/d1/` (two small files of the D-1 label check, in the F3 archive) summarises NLOG well logs of the
F3 wells. Check the NLOG terms of use.
## 2. Environment
| used for | Python | key packages | install file |
|---|---|---|---|
| P2r, P4, T2, P6, the clean-room check (Linux, NVIDIA H200, CUDA 13.0) | 3.13.15 | torch 2.14.0+cu130, numpy 2.5.4, scipy 1.18.1, pandas 3.0.6, pylops 2.5.0, numba 0.67.0 | [`requirements-linux.txt`](requirements-linux.txt) |
| P3 F3 (Windows, NVIDIA RTX 3060 12 GB) | 3.12.16 | torch 2.11.0+cu128, pandas 3.1.0, pylops 2.8.0, numba 0.68.0 | `../requirements-windows-rtx3060.txt` |
| P0–P2 (Linux) | 3.13.15 | as the first row, but numpy 2.5.3 | `../requirements-lock.txt` |
The `environment` block of `configs/protocol_{volve,bench}.lock.json` records the first row and that of
`configs/protocol_f3.lock.json` the second; the locked stages refuse to run when the installed versions differ.
```bash
python3.13 -m venv .venv
.venv/bin/pip install --extra-index-url https://download.pytorch.org/whl/cu130 -r repro/requirements-linux.txt
.venv/bin/pip install --no-deps -e .
```
The figure comparison of the clean-room check needs Ghostscript (`gs`; 10.02.1 was used). Set the thread variables
explicitly when running by hand: `OMP_NUM_THREADS=2 MKL_NUM_THREADS=2 OPENBLAS_NUM_THREADS=2`, and
`CUDA_VISIBLE_DEVICES=` for CPU-only stages.
## 3. Raw data
Only the stages that read seismic or field logs need raw data. Place them as follows and check them against the
recorded sha256 (`data_manifest/*.json`):
| dataset | source | place under | check |
|---|---|---|---|
| F3 Demo 2023 | dGB Earth Sciences, <https://terranubis.com/datainfo/F3-Demo-2023> | `data/F3_Demo_2023/F3_Demo_2023/` (or set `ML_POROSITY_F3_ROOT`) | `scripts/00_data_manifest.py --check --dataset f3` |
| Volve | Equinor, <https://www.equinor.com/energy/volve-data-sharing> (well data and the ST10010 post-stack cube) | `data/Volve/` | `scripts/00_data_manifest.py --check --dataset volve` |
| NLOG well logs | <https://www.nlog.nl> | `data/NLOG/` | `scripts/00_data_manifest.py --check --dataset nlog` |
| Teapot Dome | Texas Data Repository, doi:10.18738/T8/21WDU8 (RMOTC, U.S. Department of Energy) | `data/Teapot/raw/rmotc/` | none (inventory only) |
The protocol locks also hash their inputs, so a stage refuses to run on files that differ from the ones used.
## 4. Pipeline
Commands are run from the repository root. Run times are the wall times of the original runs (`logs/index.csv`).
Each registered phase is fixed by a protocol that was locked before its test data were generated or scored; the
locked code is that of the commit or tag in the table.
| phase (manuscript) | protocol, lock commit / tag | command | wall time, hardware | raw data |
|---|---|---|---|---|
| P0 audit (Sec. 3) | — | `scripts/run_p0.sh` (also rewrites `outputs/f3_wells.npz`, so skip it when the F3 archive is used) | under a minute, CPU | F3 SEG-Y |
| P1 field baselines (App. B) | `configs/protocol.yaml`, tag `protocol-v2` | `scripts/05_lowo.py --only B0a,B0b,B1`, `scripts/05_lowo.py --only B2,B3a,B3b --workers 12`, `scripts/06_summarize_p1.py` (the steps of `scripts/run_p1.sh` after 01 and 04) | 15 min, one GPU | none beyond the F3 archive |
| P2 first synthetic test (Sec. 6.1) | `configs/protocol_p2.yaml`, cee2ff0 | `scripts/run_p2.sh` | 1 h 29 min (main grid, 6 workers on one H200) | none beyond the F3 archive |
| P2r rerun (Sec. 6.2–6.3) | `configs/protocol_p2r.yaml`, tag `protocol-p2r` | `scripts/run_p2r_dev.sh`, then `scripts/run_p2r_main.sh` | dev 2 h 23 min; main 42 min to 1 h 38 min per regime on two H200 | none beyond the F3 archive |
| T2 mechanism, exploratory (Sec. 6.4) | declared in `docs/research/t2-mechanism.md` | `scripts/32_t2_mechanism.py` | training 18–25 min (GPU), particle tests 7 min (CPU) | none |
| Benchmark, protocol_bench (Sec. 6.5) | `configs/protocol_bench.yaml`, 381b5ff (no tag) | `scripts/run_bench.sh posterior train` per study, then `summarize`; `scripts/36_bench_verdicts.py`; `scripts/37_bench_package.py generate`, `tables` | 11.5 h in all (29/10 14:43 to 30/10 02:16 UTC), with S1, S2 and S3+S4+S8 running at once on two H200 (up to 36 workers); e.g. S2 training 3 h 8 min, S3+S4+S8 training 8 h 51 min | none |
| T3 detectability, T4 coverage, H2b bound (Sec. 6.3, 6.6) | post hoc | `scripts/27_t3_power.py`, `scripts/30_t4_coverage.py`, `scripts/31_p2r_posthoc.py` | minutes, CPU | none |
| P3 F3 field test (Sec. 6.7, App. B) | `configs/protocol_f3.yaml`, tag `protocol-f3` | `scripts/run_p3.ps1` (Windows) | 3 h 42 min on one RTX 3060 | F3 SEG-Y |
| P4 Volve field test (Sec. 6.7, App. B) | `configs/protocol_volve.yaml`, tag `protocol-volve` | `scripts/run_p4.sh` | registration 3–5 min, training 47–53 min per σ_a arm on one H200 | Volve |
| Applicability, Teapot (Sec. 6.7) | declared in `docs/research/applicability-teapot.md` | `scripts/25_p4_posthoc.py`, `scripts/26_applicability.py`, `python -P scripts/28_teapot_inventory.py`, `python -P scripts/29_teapot_pilot.py` | minutes, CPU | Teapot for 28/29 |
| Figures | — | `scripts/22_paper_figures.py`, `scripts/38_bench_figures.py` | about 2 min, CPU | none |
| Paper | — | `cd paper && pdflatex main && bibtex main && pdflatex main && pdflatex main` | seconds | — |
`../README.md` (in Vietnamese) describes every script, its options and its outputs. Stages that train resume by
skipping finished cells, so a stopped driver is restarted with the same command.
Do not rerun `scripts/01_build_wells.py`, `scripts/04_wavelet_tie.py` or `scripts/09_fit_warp_prior_f3.py` to
reproduce the manuscript: they wrote the well file, the tie files and the warp prior that the later protocols hash
(all in the F3 archive), and `scripts/run_p1.sh` and `scripts/run_p0.sh` rerun the first two. The synthetic phases
(P2, P2r, T2, protocol_bench) need no raw data: the D2 generator reads the tracked `.survey` file, the horizon
cache, the wavelet and the warp prior of the F3 archive, and `tests/test_d2_misspec.py` checks its fields against
fingerprints recorded before the benchmark was built.
**P3 and P4 from their tags.** The code-hash checks of `protocol_f3` and `protocol_volve` cover `ml_porosity/` and
`scripts/`, so every later file added to these folders makes the current tree fail them, by design. Rerun these phases
from a checkout of their tag (`git checkout protocol-f3`, `git checkout protocol-volve`) with the matching
environment. The P3 run stopped at 132/649 volume inlines on a Windows file lock; `operations/resume_f3_volume.py`
resumed only the inference (audit in `outputs/p3/volume_recovery.json` and `completion_checks.json`).
## 5. What reruns without raw data
`scripts/39_repro_package.py verify` copies the code (the tracked and untracked non-ignored files, without `logs/`,
`refs/`, `code_thesis/`, `outputs_thesis/` and `.agents/`) into an empty folder, extracts the five archives there,
deletes the paper figures and the benchmark reference tables, and runs twelve stages with that folder first on the
Python path. No SEG-Y, Volve or Teapot raw data are present; the tracked F3 well files are. An audit hook logs every
file each stage opens, and a read of the original repository counts as a failure. Each rewritten file is then
compared with the original: by bytes, then by value (csv, json, npz, md), and the figures pixel by pixel after
rasterising with Ghostscript.
```bash
CUDA_VISIBLE_DEVICES= OMP_NUM_THREADS=2 MKL_NUM_THREADS=2 OPENBLAS_NUM_THREADS=2 \
.venv/bin/python scripts/39_repro_package.py verify [--only STEP …] [--keep]
```
| stage | command | reproduces |
|---|---|---|
| p1_summary | `scripts/06_summarize_p1.py` | P1 tables (App. B) |
| p2_summary | `scripts/13_summarize_p2.py --mode main` | gate G-B, H1, H3, H4 of P2 |
| p2r_summary | `scripts/18_summarize_p2r.py` | H2a, H2b, σ_a arm, H3, H4 of P2r |
| p2r_posthoc | `scripts/31_p2r_posthoc.py` | the classical and Berkson bounds of `tab:h2b` |
| t4_coverage | `scripts/30_t4_coverage.py` | ensemble dispersion ξ and coverage (T4) |
| t3_power | `scripts/27_t3_power.py` | detectability and the crossings of Sec. 6.6 |
| bench_summarize | `scripts/34_run_bench.py summarize` | protocol_bench summary, as implemented |
| bench_verdicts | `scripts/36_bench_verdicts.py` | the 11 verdicts as worded |
| bench_tables | `scripts/37_bench_package.py tables` | `benchmark/reference/{cells.csv,main_table.md}` |
| figures_main | `scripts/22_paper_figures.py` | the manuscript figures except those of Experiment 3 |
| figures_bench | `scripts/38_bench_figures.py` | `bench_s1.pdf`, `bench_s8.pdf` |
| s8_flipband | `scripts/38_bench_figures.py --flipband` | the cos/cos² table of the S8 discussion (stdout) |
Result of the run of 2026-11-02 (04:24–04:44 UTC, 20 min on CPU; working tree at 2e4f618 with the uncommitted
changes of that day), in [`verify_report.md`](verify_report.md): all twelve stages exit 0, and no stage reads a file
outside the clean room. Of the 66 files they rewrite, 63 are identical in bytes (the eight manuscript figures:
identical pixels at 110 dpi) and 3 are equal in value: two gzip tables with zero difference, and
`outputs/bench/summary/verdict.json`, which differs only in the clean-room path it records. The 8 new files are
quick-look PNGs and the copy of the reference tables inside the benchmark package; neither is archived (the package
is a separate deposit). In the same clean room, `pytest tests/test_d2_misspec.py` passes 15/15 with none skipped,
so the D2 generator reproduces the P2r fingerprints from the tracked F3 files and the archived inputs alone.
The training stages are not part of this check: they need GPUs for hours (Section 4). Their saved predictions
and metric tables are in the archives, so every reported number is recomputed from them.
## 6. Deviations to report with the results
- **P2r** was designed after P2 failed gate G-B, on new realizations (8–15) under a new protocol. It is a deviation,
not a confirmatory replication of P2.
- **protocol_bench verdicts (D-13).** The locked `scripts/34_run_bench.py summarize` differs from the locked
statements in three places: S1-H1 needs exactly two N values but S1 has four, so it returns null; S2-H1 has no
top-level pass; S3-H1 adds the disclosed Ctl-GP control to the competitor set. `scripts/36_bench_verdicts.py`
(outside the lock; checks the lock first) applies the statements as worded. Both readings are reported:
`outputs/bench/summary/verdict.json` (as run) and `verdict_final.{json,md}` (as worded, 9/11 pass).
- **Post hoc analyses** outside every lock: `scripts/25`, `26`, `27`, `30`, `31`, `38 --flipband`. They change no
registered verdict.
- **P3 volume recovery** (Section 4): inference only, registered code and completed rows kept.
## 7. Building the package
```bash
.venv/bin/python scripts/39_repro_package.py build [--dry-run] # archives → outputs/repro/, manifest → repro/MANIFEST.json
.venv/bin/python scripts/39_repro_package.py verify # clean room → repro/verify_report.md
.venv/bin/python scripts/39_repro_package.py code --rev HEAD # git archive of a committed revision
```
`build` selects files by the first matching rule of `RULES` in the script; files without a rule stay out. `code`
refuses when the tracked files differ from the requested revision. Nothing is uploaded: the deposit (archives, code
snapshot, benchmark package) needs the authors' account, author list and licence decisions.

View File

@@ -0,0 +1,24 @@
# Linux environment of the protocol_volve and protocol_bench locks (configs/protocol_{volve,bench}.lock.json,
# "environment"), used for P2r, P4, T2, P6 and the clean-room check of repro/verify_report.md.
# Python 3.13.15, Linux x86_64, CUDA 13.0. Install:
# python3.13 -m venv .venv
# .venv/bin/pip install --extra-index-url https://download.pytorch.org/whl/cu130 -r repro/requirements-linux.txt
# .venv/bin/pip install --no-deps -e .
# The first 13 pins are the packages that the locks record; the rest are imported by the code or the tests.
# requirements-lock.txt is the older P0 environment (numpy 2.5.3); requirements-windows-rtx3060.txt is that of
# protocol_f3 (P3, Windows, Python 3.12.16).
torch==2.14.0+cu130
numpy==2.5.4
scipy==1.18.1
pandas==3.0.6
matplotlib==3.11.2
segyio==1.9.14
lasio==0.32
pylops==2.5.0
numba==0.67.0
scikit-learn==1.9.1
PyYAML==6.0.3
tabulate==0.10.0
psutil==7.2.2
pillow==12.3.0
pytest==9.1.1

84
repro/verify_report.md Normal file
View File

@@ -0,0 +1,84 @@
# Clean-room verification of the reproduction package
Written by `scripts/39_repro_package.py verify` (2026-11-02T04:24:29+00:00 → 2026-11-02T04:44:15+00:00). Code: 332 files of the working tree at 2e4f618947 with uncommitted changes; package: 11112 files from the archives listed in `repro/MANIFEST.json`; Python 3.13.15, CPU only. No SEG-Y, Volve or Teapot raw data in the clean room; the F3 well files tracked in git are present.
Status of a rewritten file: identical = same bytes as the original; equal = same values (csv/json/npz within 1e-9 relative, or bytes equal once the clean-room path is replaced by the original one; figures with < 0.01% differing pixels at 110 dpi); differs = see detail; missing = expected but not rewritten; new = written by the step but not part of the package. Reads are those of files under outputs/ (package) and data/ (tracked F3 well files); a read of the original repository would mean the clean room leaked.
| step | command | exit | s | identical | equal | differs | missing | new | reads outside package | reads of original repo |
|---|---|---|---|---|---|---|---|---|---|---|
| p1_summary | `python scripts/06_summarize_p1.py` | 0 | 2 | 2 | 0 | 0 | 0 | 1 | 0 | 0 |
| p2_summary | `python scripts/13_summarize_p2.py --mode main` | 0 | 8 | 9 | 0 | 0 | 0 | 4 | 0 | 0 |
| p2r_summary | `python scripts/18_summarize_p2r.py` | 0 | 220 | 9 | 0 | 0 | 0 | 0 | 0 | 0 |
| p2r_posthoc | `python scripts/31_p2r_posthoc.py` | 0 | 92 | 3 | 0 | 0 | 0 | 0 | 0 | 0 |
| t4_coverage | `python scripts/30_t4_coverage.py` | 0 | 26 | 4 | 1 | 0 | 0 | 0 | 0 | 0 |
| t3_power | `python scripts/27_t3_power.py` | 0 | 758 | 4 | 1 | 0 | 0 | 0 | 0 | 0 |
| bench_summarize | `python scripts/34_run_bench.py summarize` | 0 | 24 | 18 | 1 | 0 | 0 | 0 | 0 | 0 |
| bench_verdicts | `python scripts/36_bench_verdicts.py` | 0 | 9 | 3 | 0 | 0 | 0 | 0 | 0 | 0 |
| bench_tables | `python scripts/37_bench_package.py tables --out outputs/bench/package` | 0 | 13 | 2 | 0 | 0 | 0 | 3 | 0 | 0 |
| figures_main | `python scripts/22_paper_figures.py` | 0 | 5 | 6 | 0 | 0 | 0 | 0 | 0 | 0 |
| figures_bench | `python scripts/38_bench_figures.py` | 0 | 8 | 2 | 0 | 0 | 0 | 0 | 0 | 0 |
| s8_flipband | `python scripts/38_bench_figures.py --flipband` | 0 | 8 | 1 | 0 | 0 | 0 | 0 | 0 | 0 |
Paper figures deleted from the clean room and not regenerated: none.
## Details
### p1_summary
- package files read: 5
- new: `outputs/figures/p1_lowo.png`
- identical: 2 file(s)
### p2_summary
- package files read: 293
- new: `outputs/figures/p2_band_lines.png`
- new: `outputs/figures/p2_h1.png`
- new: `outputs/figures/p2_h3.png`
- new: `outputs/figures/p2_phase.png`
- identical: 9 file(s)
### p2r_summary
- package files read: 524
- identical: 9 file(s)
### p2r_posthoc
- package files read: 244
- identical: 3 file(s)
### t4_coverage
- package files read: 274
- equal: `outputs/t4/wells.csv.gz` (max rel. diff 0.0e+00)
- identical: 4 file(s)
### t3_power
- package files read: 49
- equal: `outputs/t3/indicators.csv.gz` (max rel. diff 0.0e+00)
- identical: 4 file(s)
### bench_summarize
- package files read: 3226
- equal: `outputs/bench/summary/verdict.json` (differs only in the clean-room path)
- identical: 18 file(s)
### bench_verdicts
- package files read: 589; tracked data read: data/F3_Demo_2023/F3_Demo_2023
- identical: 3 file(s)
### bench_tables
- package files read: 3226; tracked data read: data/F3_Demo_2023/F3_Demo_2023
- new: `outputs/bench/package/reference/cells.csv`
- new: `outputs/bench/package/reference/main_table.md`
- new: `outputs/bench/package/reference/runs.csv.gz`
- identical: 2 file(s)
### figures_main
- package files read: 12; tracked data read: data/F3_Demo_2023/F3_Demo_2023
- identical: 6 file(s)
### figures_bench
- package files read: 156; tracked data read: data/F3_Demo_2023/F3_Demo_2023
- identical: 2 file(s)
### s8_flipband
- package files read: 203; tracked data read: data/F3_Demo_2023/F3_Demo_2023
- identical: 1 file(s)

View File

@@ -0,0 +1,149 @@
"""Final verdicts of protocol_bench (phase P6): the 11 pre-declared verdicts read exactly as their statements are worded.
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/36_bench_verdicts.py
Runs after `scripts/34_run_bench.py summarize` and never edits its outputs. The locked summary code
(ml_porosity/benchmark/summary.py) computes every cell correctly, but three verdict extractions differ from the
statements of configs/protocol_bench.yaml (found after the main runs, before any paper text used them):
S1-H1 the statement names N ∈ {4, 16}; the code requires exactly two R10 c = 1.5 rows, but S1 has four N values
(2, 4, 8, 16), so it returns pass = null. Here: the two rows N ∈ {4, 16} of s1_h2a.csv.
S2-H1 the code stores one verdict per axis (per_axis) and no top-level `pass`, so summary.md prints
"not available". Here: per axis from s2_h2a.csv (R10, preset *_L1, c = 1, N ∈ {4, 16}).
S3-H1 the statement fixes the competitors {B3b, B3c, B3c-R, B4a, B4b, B4c, B4d}; the code uses POINT_TIES + every
S3 method, which adds the disclosed control bank Ctl-GP (T2-1). Ctl-GP uses the posterior mean and
covariance, so it is not a point tie or an anchor-free baseline. Here: h2a_cells of the locked code with the
stated set (bootstrap rng 0, 2000 resamples, one generator per regime in the summary's regime order).
The other eight verdicts are copied from verdict.json. Both readings are written side by side; the as-run S3-H1
result (with Ctl-GP) stays reported. The lock is checked first (code, protocol, inputs).
→ outputs/bench/summary/verdict_final.json, verdict_final.md, s3_h2a_stated.csv
"""
from __future__ import annotations
import json
import numpy as np
import pandas as pd
from ml_porosity.benchmark import summary as S
from ml_porosity.benchmark.cells import bench_root
from ml_porosity.benchmark.protocol import freeze, load_protocol
S3_COMP = S.POINT_TIES + ["B4a", "B4b", "B4c", "B4d"]
H2A_REGIMES = ["R10", "R0", "Rm5"]
ORDER = ["S1-H1", "S1-H2", "S2-H1/rock_physics", "S2-H1/wavelet", "S2-H1/drift", "S2-H2", "S3-H1", "S4-H1", "S4-H2",
"S8-H1", "S8-H2"]
PRED_S2 = {"rock_physics": "pass", "wavelet": "pass (phase sub-axis wv_L1)", "drift": "uncertain"} # S2-H1.prediction
def _cell(r) -> dict:
return {"best": r.best, "ratio": float(r.ratio), "ci": [float(r.ratio_lo), float(r.ratio_hi)], "dpcc": float(r.dpcc),
"seeds_improve": int(r.seeds_improve), "rids_improve": int(r.rids_improve), "cell_pass": bool(r.cell_pass)}
def s1_h1(out, n_rid: int) -> dict:
t = pd.read_csv(out / "s1_h2a.csv")
t = t[(t.regime == "R10") & (t.c == 1.5) & t.n_train.isin([4, 16])]
ok = len(t) == 2 and bool((t.n_rid == n_rid).all())
return {"cells": {int(r.n_train): _cell(r) for r in t.itertuples()}, "complete": ok,
"pass": bool(t.cell_pass.all()) if ok else None}
def s2_h1(out, n_rid: int) -> dict:
t = pd.read_csv(out / "s2_h2a.csv")
t = t[(t.regime == "R10") & t.preset.str.endswith("_L1") & (t.c == 1) & t.n_train.isin([4, 16])]
res = {}
for axis, g in t.groupby("axis"):
ok = len(g) == 2 and bool((g.n_rid == n_rid).all())
res[axis] = {"preset": g.preset.iloc[0], "cells": {int(r.n_train): _cell(r) for r in g.itertuples()},
"complete": ok, "pass": bool(g.cell_pass.all()) if ok else None}
return res
def s3_h1(p: dict, n_boot: int) -> tuple[dict, pd.DataFrame]:
_, run_b4, _ = S.load_study(p, bench_root(dev=False), "S3")
run = pd.concat([S.p2r_runs(p), run_b4], ignore_index=True)
assert set(S3_COMP) <= set(run.method), sorted(run.method.unique())
rows, per = [], {}
for reg, g in run.groupby("regime"):
cells = S.h2a_cells(g, "B3d-Sa", S3_COMP, np.random.default_rng(0), n_boot)
rows.append(cells.assign(regime=reg, flag=np.where(cells.c == 2, "unstable posterior", "")))
c1, c0 = cells[cells.c == 1], cells[cells.c == 0]
macro = float(c0.m2_band_rmse.mean() / c0.best_band_rmse.mean())
guard = bool(len(c0) == 2 and macro <= S.sp13.GUARD and (c0.ratio <= S.sp13.GUARD).all())
per[reg] = {"c1_cells": {int(r.n_train): _cell(r) for r in c1.itertuples()},
"zero_drift_ratios": {int(r.n_train): float(r.ratio) for r in c0.itertuples()},
"zero_drift_macro_ratio": macro, "zero_drift_guard": guard,
"regime_pass": bool(len(c1) == 2 and c1.cell_pass.all() and guard),
"b4_best_anywhere": sorted({f"c{r.c:g}/N{r.n_train}:{r.best}" for r in cells.itertuples() if r.best.startswith("B4")}),
"complete": bool(len(cells) == 6 and (cells.n_rid == len(p["grid"]["realizations"])).all())}
v = {"competitors": S3_COMP, "per_regime": per, "pass": per.get("R10", {}).get("regime_pass"),
"regimes_pass": [r for r in H2A_REGIMES if per.get(r, {}).get("regime_pass")]}
return v, pd.concat(rows, ignore_index=True)
def main() -> None:
freeze(check=True)
p = load_protocol()
out = bench_root(dev=False) / "summary"
raw = json.loads((out / "verdict.json").read_text())
n_rid, n_boot = len(p["grid"]["realizations"]), 2000
s3, s3_tab = s3_h1(p, n_boot)
s3_tab.to_csv(out / "s3_h2a_stated.csv", index=False)
s2 = s2_h1(out, n_rid)
as_run = {"S1-H1": raw["S1"]["S1-H1"].get("pass"), "S1-H2": raw["S1"]["S1-H2"]["pass"],
**{f"S2-H1/{a}": raw["S2"]["S2-H1"]["per_axis"][a]["pass"] for a in ("rock_physics", "wavelet", "drift")},
"S2-H2": raw["S2"]["S2-H2"]["pass"], "S3-H1": raw["S3"]["pass"], "S4-H1": raw["S4"]["S4-H1"]["pass"],
"S4-H2": raw["S4"]["S4-H2"]["pass"], "S8-H1": raw["S8"]["S8-H1"]["pass"], "S8-H2": raw["S8"]["S8-H2"]["pass"]}
detail = {"S1-H1": s1_h1(out, n_rid), "S1-H2": raw["S1"]["S1-H2"],
**{f"S2-H1/{a}": s2[a] for a in ("rock_physics", "wavelet", "drift")},
"S2-H2": raw["S2"]["S2-H2"], "S3-H1": s3, "S4-H1": raw["S4"]["S4-H1"], "S4-H2": raw["S4"]["S4-H2"],
"S8-H1": raw["S8"]["S8-H1"], "S8-H2": raw["S8"]["S8-H2"]}
final = {k: detail[k]["pass"] for k in ORDER}
for a in ("rock_physics", "wavelet", "drift"): # the per-axis extraction of the code is correct
assert final[f"S2-H1/{a}"] == as_run[f"S2-H1/{a}"], a
note = {"S1-H1": "code filter: exactly 2 rows at R10 c = 1.5 (S1 has N = 2, 4, 8, 16) → null; statement: N ∈ {4, 16}",
"S3-H1": "code competitors include Ctl-GP (POINT_TIES + S3 methods); statement: {B3b, B3c, B3c-R, B4a–d}"}
verdict = {"protocol_sha256": raw["protocol_sha256"], "source": "outputs/bench/summary/verdict.json (scripts/34 summarize)",
"final": final, "as_run": as_run, "differences": note, "detail": detail,
"passed": [k for k in ORDER if final[k]], "failed": [k for k in ORDER if final[k] is False],
"S2_axes_pass": [a for a in ("rock_physics", "wavelet", "drift") if final[f"S2-H1/{a}"]]}
(out / "verdict_final.json").write_text(json.dumps(verdict, indent=1, default=float))
hyp = p["hypotheses"]
fmt = lambda x: "PASS" if x else "FAIL" if x is False else "null"
L = ["# protocol_bench final verdicts (scripts/36_bench_verdicts.py)", "",
f"Protocol sha256 {raw['protocol_sha256'][:12]}…; lock checked. Statements of configs/protocol_bench.yaml applied as "
"written; `as run` is verdict.json of scripts/34 summarize (locked code). No family-wise correction (11 verdicts).", "",
"| verdict | final | as run | prediction | note |", "|---|---|---|---|---|"]
for k in ORDER:
pred = PRED_S2[k.split("/")[1]] if k.startswith("S2-H1") else str(hyp[k]["prediction"]).split(";")[0].strip()
L.append(f"| {k} | **{fmt(final[k])}** | {fmt(as_run[k])} | {pred} | {note.get(k, '')} |")
L += ["", "## S1-H1 (R10, c = 1.5)", ""]
L += [f"- N = {n}: best {c['best']}, ratio {c['ratio']:.3f} [{c['ci'][0]:.3f}, {c['ci'][1]:.3f}], ΔPCC {c['dpcc']:+.3f}, "
f"seeds {c['seeds_improve']}/5, rids {c['rids_improve']}/{n_rid}, cell_pass {c['cell_pass']}" for n, c in detail["S1-H1"]["cells"].items()]
L += ["", "## S2-H1 per axis (R10, L1, c = 1)", ""]
for a in ("rock_physics", "wavelet", "drift"):
d = detail[f"S2-H1/{a}"]
L += [f"- {a} ({d['preset']}), N = {n}: best {c['best']}, ratio {c['ratio']:.3f} [{c['ci'][0]:.3f}, {c['ci'][1]:.3f}], "
f"ΔPCC {c['dpcc']:+.3f}, seeds {c['seeds_improve']}/5, rids {c['rids_improve']}/{n_rid} → {fmt(c['cell_pass'])}"
for n, c in d["cells"].items()]
L += ["", "## S3-H1 with the stated competitors", "", "| regime | c = 1, N = 4 | c = 1, N = 16 | c = 0 guard (macro) | regime | B4 best in |",
"|---|---|---|---|---|---|"]
for reg, d in s3["per_regime"].items():
cc = [f"{d['c1_cells'][n]['ratio']:.3f} ({d['c1_cells'][n]['best']}) {fmt(d['c1_cells'][n]['cell_pass'])}" for n in (4, 16)]
L.append(f"| {reg} | {cc[0]} | {cc[1]} | {fmt(d['zero_drift_guard'])} ({d['zero_drift_macro_ratio']:.3f}) | "
f"{fmt(d['regime_pass'])} | {', '.join(d['b4_best_anywhere']) or '—'} |")
r = raw["S3"]["per_regime"]
L += ["", f"As run (with Ctl-GP): best at c = 1 is Ctl-GP in {sum(v['best_at_c1'] == {'4': 'Ctl-GP', '16': 'Ctl-GP'} for v in r.values())}/{len(r)} "
f"regimes; R10 zero-drift macro ratio {r['R10']['zero_drift_macro_ratio']:.4f} → regime fail. Kept as a disclosed reading "
"(see T2-1 in verdict.json).", ""]
(out / "verdict_final.md").write_text("\n".join(L))
print("\n".join(L))
if __name__ == "__main__":
main()

490
scripts/37_bench_package.py Normal file
View File

@@ -0,0 +1,490 @@
"""S7 packaging of protocol_bench (phase P6): the registration-aware benchmark as files, with one command to generate
the tasks and one command to score predictions against the reference methods.
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py generate [--out DIR] [--split test dev]
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py tables [--out DIR]
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py score --pred DIR --name NAME [--out DIR]
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py selftest [--out DIR]
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/37_bench_package.py check [--out DIR]
DIR defaults to outputs/bench/package. Documentation for users of the benchmark: benchmark/README.md.
generate One npz per task (setting, c, realization) in DIR/tasks/<split>/<setting>/, the hidden truth in
DIR/truth/<split>/<setting>/, the generator inputs and the analyst's knowledge in DIR/inputs/, an index
(DIR/tasks/index.csv) and DIR/MANIFEST.json. The manifest records the sha256 of the array content of each
file (key, dtype, shape, bytes; independent of zip metadata). The first run writes benchmark/MANIFEST.json
(tracked in git); later runs must reproduce it exactly or fail (--update-manifest overwrites it).
Observations are those of the runner (ml_porosity.benchmark.data.Inputs.observe): the 16 pool wells (a
task with N training wells uses the first N) and the 8 test wells at the regime SNR.
tables Reference runs of every method of protocol_p2r and protocol_bench at its registered budget, one row per
(setting, c, N, realization, seed, method) → DIR/reference/runs.csv.gz, and the per-cell means with σ_post
→ benchmark/reference/cells.csv and benchmark/reference/main_table.md (and copies in DIR/reference/).
score Predictions <pred>/<split>/<setting>/r{rid}_c{c}_n{N}_s{seed}.npz with `mu` (8, 126) and optionally `sigma`
(8, 126), porosity in p.u., test wells in task order. Metrics are those of the runner (scripts/11 evaluate).
On the test split the locked rules of ml_porosity/benchmark/summary.py are applied per cell: the H2a cell
rule against the best point tie {B3b, B3c, B3c-R}, and the `better` rule against B3d-Sa, M2-Sa, Oracle
(PM2, BK2, Oracle in the two-mode settings). Reference rows are restricted to the submitted realizations and
seeds. Bootstrap CIs use one generator (rng 0) per cell, so they can differ slightly from the summary
tables; no rule uses a CI. → <pred>/score/
selftest Writes saved predictions of reference methods as a submission (S1 R10 c = 1.5, S2 R10 wv_L1, P2r R10 c = 1,
S8 R10 Δ = 16), scores it, and checks that metrics and rule outputs equal those of the reference runs and
that the package truth equals the y_true saved by the runner.
check Recomputes the content hashes of DIR against benchmark/MANIFEST.json (for a downloaded copy).
Outside the code hash of the protocol_bench lock (scripts/34 and ml_porosity/ only); generate and tables check the
lock first. Nothing here trains a model or changes a locked output.
"""
from __future__ import annotations
import argparse
import hashlib
import json
import math
import re
import shutil
from pathlib import Path
import numpy as np
import pandas as pd
from ml_porosity.benchmark import summary as S
from ml_porosity.benchmark.cells import bench_root
from ml_porosity.benchmark.data import load_inputs, load_script
from ml_porosity.benchmark.protocol import freeze, load_protocol
from ml_porosity.benchmark.training import SIDE_STREAM
from ml_porosity.data import synth_d2
from ml_porosity.paths import REPO_ROOT, outputs_dir
PKG = outputs_dir() / "bench" / "package"
DOC = REPO_ROOT / "benchmark"
GAUSS = ["nll", "crps", "mean_sigma", "coverage_50", "coverage_80", "coverage_90", "coverage_95"]
CELL = ["setting", "c", "n_train"]
RUN = ["setting", "c", "n_train", "rid", "seed", "method"]
PRED = re.compile(r"r(\d+)_c([\d.]+)_n(\d+)_s(\d+)")
WIDE_MS = 1.5 # rules.wide of protocol_bench
N_BOOT = 2000
# ---------------------------------------------------------------- tasks
def settings(p: dict) -> list[dict]:
"""Every (regime, preset, Δ) of the benchmark with its drift factors: S1 (nominal), S2 (presets), S8 (two-mode)."""
st = p["studies"]
out = [dict(setting=r, regime=r, preset="nominal", delta_ms=None, cs=st["S1"]["drift_factors"]) for r in p["grid"]["regimes"]]
out += [dict(setting=f"{r}__{pr}", regime=r, preset=pr, delta_ms=None, cs=st["S2"]["drift_factors"])
for r in st["S2"]["regimes"] for axis in st["S2"]["presets"].values() for pr in axis]
out += [dict(setting=f"{r}__s8d{d:g}", regime=r, preset="nominal", delta_ms=float(d), cs=st["S8"]["drift_factors"])
for r in st["S8"]["regimes"] for d in st["S8"]["delta_ms"]]
return out
def task_arrays(inp, R, s: dict, c: float) -> tuple[dict, dict]:
reg = inp.regime(s["regime"])
obs, test = inp.observe(R, c, s["regime"], len(R.pool))
task = {"rid": np.int64(R.rid), "c": np.float64(c), "snr_db": np.float64(reg["snr_db"]),
"anchor_density": np.array(reg["anchor_density"]), "sigma_a_ms": np.float64(inp.sigma_a),
"t_seis_ms": R.t_ext, "t_label_ms": R.t_main, "tau_ms": R.tau_fine,
"train_names": np.array([o["name"] for o in obs]), "train_seis": np.stack([o["seis"] for o in obs]),
"train_phi_log": np.stack([o["phi_log"] for o in obs]), "train_ai_log": np.stack([o["ai_log"] for o in obs]),
"train_ilxl": np.array([[w.il, w.xl] for w in R.pool]), "train_xy": np.array([[w.x, w.y] for w in R.pool]),
"anchor_well": np.concatenate([np.full(len(o["tau_k"]), i) for i, o in enumerate(obs)]),
"anchor_tau_ms": np.concatenate([o["tau_k"] for o in obs]), "anchor_t_ms": np.concatenate([o["t_k"] for o in obs]),
"test_names": np.array([o["name"] for o in test]), "test_seis": np.stack([o["seis"] for o in test]),
"test_ilxl": np.array([[w.il, w.xl] for w in R.test]), "test_xy": np.array([[w.x, w.y] for w in R.test])}
truth = {"y_test": 100 * np.stack([o["y_true"] for o in test]), "test_names": task["test_names"],
"train_t_of_tau_ms": np.stack([o["t_of_tau_true"] for o in obs]),
"train_b_ms": np.array([o["b"] for o in obs]), "train_g": np.stack([o["g"] for o in obs])}
if s["delta_ms"] is not None: # S8: modes t_true and t_true + s·Δ (training.two_mode_banks)
d = s["delta_ms"]
side = np.array([int(np.random.default_rng([R.rid, SIDE_STREAM, 8, i]).integers(2)) * 2 - 1 for i in range(len(obs))])
task |= {"delta_ms": np.float64(d),
"two_mode_t_of_tau_ms": np.stack([np.stack([o["t_of_tau_true"], o["t_of_tau_true"] + si * d])
for o, si in zip(obs, side)])}
truth["two_mode_side"] = side
return task, truth
def content_sha(arrs: dict) -> str:
h = hashlib.sha256()
for k in sorted(arrs):
a = np.ascontiguousarray(np.asarray(arrs[k]))
h.update(f"{k}|{a.dtype.str}|{a.shape}|".encode())
h.update(a.tobytes())
return h.hexdigest()
def npz_sha(f: Path) -> str:
with np.load(f) as z:
return content_sha({k: z[k] for k in z.files})
def file_sha(f: Path) -> str:
return hashlib.sha256(f.read_bytes()).hexdigest()
def analyst(p: dict, inp) -> dict:
"""What a method may assume: the analyst's (nominal) wavelet, warp prior, anchor noise and rock physics."""
cfg, wp = inp.cfg, p["inputs"]["warp_prior"]
return {
"units": {"time": "ms two-way time", "tau": "ms sonic time τ of the logs (0.5 ms grid)",
"labels": "porosity in percent (p.u.) = 100 × fraction", "phi_log": "porosity fraction"},
"seismic": {"dt_ms": cfg["dt_ms"], "window_ms": cfg["ext_window_ms"], "label_window_ms": cfg["main_window_ms"],
"patch": "3 × 3 traces around each well: inline offset −1..1 (outer) × crossline offset −1..1 "
"(inner); the centre trace is index 4; labels refer to the centre trace"},
"anchors": {"sigma_a_ms": inp.sigma_a,
"model": "unit-boundary picks: anchor_tau_ms exact on the log, anchor_t_ms = true time + N(0, σ_a²)"},
"rock_physics_nominal": {"phi_dt": [synth_d2.PHI_DT_A, synth_d2.PHI_DT_B], "rhob": [synth_d2.RHO_0, synth_d2.RHO_1],
"formula": "DT = (φ − A)/B µs/m; RHOB = ρ0 − ρ1·φ kg/m³; AI = RHOB·1e6/DT; "
"train_ai_log = AI(train_phi_log)"},
"wavelet_nominal": {"file": "inputs/wavelets.npz", "key": p["inputs"]["wavelet"]["key"], "dt_ms": cfg["dt_ms"],
"note": "zero phase; the reference registrations re-estimate a constant phase on a 15° grid"},
"warp_prior": {"file": "inputs/warp_prior_f3.json", "fit": wp["fit"], "hyper": inp.prior_hyper,
"sigma_b_ms": inp.reg["sigma_b_ms"],
"model": "t(τ) = b + ∫ exp(g) dτ on a 4 ms τ grid; g a stationary GP (fit), b ~ N(0, σ_b²)"},
"metric": {"primary": "band RMSE: RMSE after a 4th-order zero-phase Butterworth high-pass at f_c, mean over "
"the 8 test wells", "f_c_hz": inp.f_c, "secondary": "band PCC"},
}
def generate(a) -> None:
if not a.skip_lock_check:
freeze(check=True)
p = load_protocol()
inp = load_inputs(p)
out = Path(a.out)
rids = {"test": p["grid"]["realizations"], "dev": p["grid"]["dev_realizations"]}
for d in ("tasks", "truth"):
for sp in a.split:
shutil.rmtree(out / d / sp, ignore_errors=True)
rows, files = [], {}
for sp in a.split:
for rid in rids[sp]:
cache = {}
for s in settings(p):
R = cache.get(s["preset"]) or cache.setdefault(s["preset"], inp.realization(rid, None if s["preset"] == "nominal" else s["preset"]))
for c in s["cs"]:
task, truth = task_arrays(inp, R, s, float(c))
rel = Path(sp) / s["setting"] / f"r{rid}_c{float(c):g}.npz"
for d, arr in (("tasks", task), ("truth", truth)):
(out / d / rel).parent.mkdir(parents=True, exist_ok=True)
np.savez_compressed(out / d / rel, **arr)
files[f"{d}/{rel}"] = content_sha(arr)
rows.append({"split": sp, "setting": s["setting"], "regime": s["regime"], "preset": s["preset"],
"delta_ms": s["delta_ms"], "c": float(c), "rid": rid, "snr_db": float(task["snr_db"]),
"anchor_density": str(task["anchor_density"]), "n_pool": len(task["train_names"]),
"n_test": len(task["test_names"]), "n_anchors": len(task["anchor_tau_ms"]),
"task": f"tasks/{rel}", "truth": f"truth/{rel}"})
print(f"{sp} r{rid}: {sum(r['rid'] == rid and r['split'] == sp for r in rows)} tasks", flush=True)
idx = pd.DataFrame(rows)
if (out / "tasks" / "index.csv").exists(): # keep the rows of splits not regenerated
old = pd.read_csv(out / "tasks" / "index.csv")
idx = pd.concat([old[~old.split.isin(a.split)], idx], ignore_index=True)
idx.to_csv(out / "tasks" / "index.csv", index=False)
src = out / "inputs"
src.mkdir(parents=True, exist_ok=True)
for k in ("d2_config", "warp_prior", "wavelet", "horizon_cache"):
shutil.copy2(REPO_ROOT / p["inputs"][k]["path"], src / Path(p["inputs"][k]["path"]).name)
shutil.copy2(REPO_ROOT / "configs" / "protocol_bench.yaml", src / "protocol_bench.yaml")
(src / "analyst.json").write_text(json.dumps(analyst(p, inp), indent=1, ensure_ascii=False, default=float))
old = json.loads((out / "MANIFEST.json").read_text()) if (out / "MANIFEST.json").exists() else {}
keep = {k: v for k, v in old.get("files", {}).items() if k.split("/")[1] not in a.split}
lock = json.loads((REPO_ROOT / "configs" / "protocol_bench.lock.json").read_text())
man = {"benchmark": "protocol_bench v1 (registration-aware D2 benchmark)", "protocol_sha256": lock["protocol_sha256"],
"code_sha256_at_lock": lock["code_sha256"], "hash": "sha256 of array content: for each key in sorted order, "
"'key|dtype|shape|' then the C-order bytes (scripts/37_bench_package.py content_sha)",
"inputs": {f"inputs/{f.name}": file_sha(f) for f in sorted(src.iterdir()) if f.name != "analyst.json"},
"splits": {sp: rids[sp] for sp in sorted(set(old.get("splits", {})) | set(a.split))},
"n_tasks": int(len(idx)), "files": dict(sorted((keep | files).items()))}
(out / "MANIFEST.json").write_text(json.dumps(man, indent=1))
ref = DOC / "MANIFEST.json"
if ref.exists() and not a.update_manifest:
want = json.loads(ref.read_text())
bad = [k for k, v in man["files"].items() if want["files"].get(k) != v]
bad += [k for k in want["files"] if k.split("/")[1] in a.split and k not in man["files"]]
if bad or want["inputs"] != man["inputs"]:
raise SystemExit(f"generated content differs from benchmark/MANIFEST.json: {len(bad)} files, e.g. {bad[:3]}; "
f"inputs equal: {want['inputs'] == man['inputs']}")
print(f"content hashes equal to benchmark/MANIFEST.json ({len(man['files'])} files)")
else:
DOC.mkdir(exist_ok=True)
shutil.copy2(out / "MANIFEST.json", ref)
print(f"wrote benchmark/MANIFEST.json ({len(man['files'])} files)")
if (DOC / "README.md").exists():
shutil.copy2(DOC / "README.md", out / "README.md")
print(f"{len(idx)} tasks → {out}")
def check(a) -> None:
out, want = Path(a.out), json.loads((DOC / "MANIFEST.json").read_text())
bad = [k for k, v in want["files"].items() if not (out / k).exists() or npz_sha(out / k) != v]
bad += [k for k, v in want["inputs"].items() if not (out / k).exists() or file_sha(out / k) != v]
print(f"{len(want['files']) + len(want['inputs']) - len(bad)}/{len(want['files']) + len(want['inputs'])} files match")
if bad:
raise SystemExit(f"mismatch: {bad[:10]}")
# ---------------------------------------------------------------- reference tables
def setting_of(df: pd.DataFrame) -> pd.Series:
preset = df["preset"].fillna("nominal")
d = df["delta_ms"] if "delta_ms" in df else pd.Series(np.nan, index=df.index)
s8 = df["regime"] + "__s8d" + d.map(lambda x: f"{x:g}" if pd.notna(x) else "")
return pd.Series(np.where(d.notna(), s8, np.where(preset == "nominal", df["regime"], df["regime"] + "__" + preset)),
index=df.index)
def reference_runs(p: dict) -> pd.DataFrame:
parts = [S.p2r_runs(p).assign(study="P2r")]
for st in ("S1", "S2", "S3", "S4", "S8"):
parts.append(S.load_study(p, bench_root(), st)[1].assign(study=st))
df = pd.concat(parts, ignore_index=True)
df["preset"] = df["preset"].fillna("nominal")
df["setting"] = setting_of(df)
dup = df.duplicated(RUN)
if dup.any():
raise RuntimeError(f"{int(dup.sum())} duplicated reference runs, e.g. {df[dup][RUN].head(3).to_dict('records')}")
return df[["study", "regime", "preset", "delta_ms", *RUN, *S.METRICS]].sort_values(RUN).reset_index(drop=True)
def sigma_post(p: dict) -> pd.DataFrame:
a = pd.read_csv(REPO_ROOT / p["reference"]["p2r"]["root"] / "summary" / "sigma_post.csv")
d = bench_root() / "posterior"
b = S.sigma_post_table({x.name: x for x in sorted(d.iterdir()) if x.is_dir()})
cols = ["setting", "c", "n_train", "sigma_post_ms", "warp_rmse_ms", "warp_cov90"]
return pd.concat([a[cols], b[cols]], ignore_index=True)
def tables(a) -> None:
freeze(check=True)
p = load_protocol()
out = Path(a.out) / "reference"
out.mkdir(parents=True, exist_ok=True)
runs = reference_runs(p)
runs.to_csv(out / "runs.csv.gz", index=False, float_format="%.10g")
g = runs.groupby(["setting", "regime", "preset", "delta_ms", "c", "n_train", "method"], dropna=False)
cells = g.agg(n_rid=("rid", "nunique"), n_seed=("seed", "nunique"), band_rmse=("band_rmse", "mean"),
band_pcc=("band_pcc", "mean"), rmse=("rmse", "mean"), pcc=("pcc", "mean"), crps=("crps", "mean"),
coverage_90=("coverage_90", "mean")).reset_index()
sp = sigma_post(p)
if sp.duplicated(CELL).any():
raise RuntimeError("duplicated σ_post cells")
cells = cells.merge(sp, on=CELL, how="left")
cells["wide"] = np.where(cells.sigma_post_ms.notna(), cells.sigma_post_ms >= WIDE_MS, np.nan)
rdoc = DOC / "reference"
rdoc.mkdir(parents=True, exist_ok=True)
cells.to_csv(rdoc / "cells.csv", index=False, float_format="%.6g")
shutil.copy2(rdoc / "cells.csv", out / "cells.csv")
main = cells[(cells.preset == "nominal") & cells.delta_ms.isna() & (cells.c == 1) & cells.n_train.isin([4, 16])]
order = ["Oracle", "B3b", "B3c", "B3c-R", "B3d", "B4a", "B4b", "B4c", "B4d", "B3d-Sa", "M2-Sa", "Ctl-GP"]
t = main.pivot_table(index="method", columns=["setting", "n_train"], values="band_rmse").reindex(order).dropna(how="all")
regs = [r for r in p["grid"]["regimes"] if r in t.columns.get_level_values(0)]
head = "| method | " + " | ".join(f"{r} N={n}" for r in regs for n in (4, 16)) + " |"
L = ["# Reference band RMSE (p.u.), nominal settings, c = 1", "",
"Mean over 8 test realizations × 5 network seeds at the registered budgets (CNN–GRU). σ_post (ms) is the "
"SMC posterior width over the training wells; 'wide' means σ_post ≥ 1.5 ms. Full table: cells.csv.", "",
head, "|" + "---|" * (1 + 2 * len(regs))]
for m, r in t.iterrows():
L.append(f"| {m} | " + " | ".join(f"{r.get((g, n), np.nan):.3f}" for g in regs for n in (4, 16)) + " |")
s1 = main.drop_duplicates(CELL).set_index(["setting", "n_train"])["sigma_post_ms"]
L.append("| σ_post | " + " | ".join(f"{s1.get((g, n), np.nan):.2f}" for g in regs for n in (4, 16)) + " |")
(rdoc / "main_table.md").write_text("\n".join(L) + "\n")
shutil.copy2(rdoc / "main_table.md", out / "main_table.md")
print("\n".join(L))
print(f"{len(runs)} reference runs, {len(cells)} cell rows → {out}, {rdoc}")
# ---------------------------------------------------------------- scoring
def read_predictions(pred: Path, pkg: Path, name: str, f_c: float) -> pd.DataFrame:
run_d2 = load_script("11_run_d2.py")
rows = []
files = sorted(f for f in pred.glob("*/*/r*_c*_n*_s*.npz") if f.parent.parent.name in ("test", "dev"))
if not files:
raise SystemExit(f"no predictions under {pred}/<split>/<setting>/r<rid>_c<c>_n<N>_s<seed>.npz")
for f in files:
m = PRED.fullmatch(f.stem)
if m is None:
raise SystemExit(f"{f}: name must be r<rid>_c<c>_n<N>_s<seed>.npz")
rid, c, N, seed = int(m[1]), float(m[2]), int(m[3]), int(m[4])
split, setting = f.parent.parent.name, f.parent.name
tf = pkg / "truth" / split / setting / f"r{rid}_c{c:g}.npz"
if not tf.exists():
raise SystemExit(f"{f}: no task {tf.relative_to(pkg)}")
if not 1 <= N <= 16:
raise SystemExit(f"{f}: N = {N} outside 1..16")
with np.load(tf) as t:
yt, names = t["y_test"], t["test_names"]
with np.load(f) as z:
mu = z["mu"].astype(float)
sg = z["sigma"].astype(float) if "sigma" in z.files else None
if mu.shape != yt.shape or not np.isfinite(mu).all():
raise SystemExit(f"{f}: mu must be finite with shape {yt.shape}, got {mu.shape}")
if sg is not None and (sg.shape != yt.shape or not (np.isfinite(sg).all() and (sg > 0).all())):
raise SystemExit(f"{f}: sigma must be finite, positive, shape {yt.shape}")
with np.errstate(all="ignore"):
res = run_d2.evaluate(yt, mu, np.ones_like(mu) if sg is None else sg, f_c)
for w, r in zip(names, res):
if sg is None:
r = r | {k: np.nan for k in GAUSS}
rows.append({"split": split, "setting": setting, "c": c, "n_train": N, "rid": rid, "seed": seed,
"method": name, "test_well": str(w)} | r)
return pd.DataFrame(rows)
def rule_tables(run: pd.DataFrame, ref: pd.DataFrame, name: str) -> tuple[pd.DataFrame, pd.DataFrame, pd.DataFrame]:
rules, pairs, means = [], [], []
for (setting, c, N), sub in run.groupby(CELL):
r = ref[(ref.setting == setting) & (ref.c == c) & (ref.n_train == N) & ref.rid.isin(sub.rid) & ref.seed.isin(sub.seed)]
both = pd.concat([sub[RUN + S.METRICS], r[RUN + S.METRICS]], ignore_index=True)
key = {"setting": setting, "c": c, "n_train": N, "n_rid": sub.rid.nunique(), "n_seed": sub.seed.nunique()}
means.append(key | both.groupby("method").band_rmse.mean().add_prefix("band_rmse_").to_dict())
if set(S.POINT_TIES) <= set(r.method):
cells = S.h2a_cells(both, name, S.POINT_TIES, np.random.default_rng(0), N_BOOT)
rules.append(cells.drop(columns=["c", "n_train", "n_rid", "n_seed"]).assign(**key))
for m in ("B3d-Sa", "M2-Sa", "PM2", "BK2", "Oracle"):
if m in set(r.method):
d = S.pair(both, name, m, np.random.default_rng(0), N_BOOT)
pairs.append(key | {"reference": m} | d)
first = lambda df, cols: df[[*cols, *[k for k in df.columns if k not in cols]]] if len(df) else df
k = ["setting", "c", "n_train", "n_rid", "n_seed"]
rules = pd.concat(rules, ignore_index=True) if rules else pd.DataFrame()
return first(rules, k), first(pd.DataFrame(pairs), k + ["reference"]), first(pd.DataFrame(means), k)
def score(a) -> None:
pkg, pred = Path(a.out), Path(a.pred)
ref = pd.read_csv(pkg / "reference" / "runs.csv.gz")
if a.name in set(ref.method) or a.name == "M2":
raise SystemExit(f"--name {a.name} is a reference method name; choose another")
f_c = float(json.loads((pkg / "inputs" / "analyst.json").read_text())["metric"]["f_c_hz"])
well = read_predictions(pred, pkg, a.name, f_c)
run = well.groupby(["split", *RUN], as_index=False)[S.METRICS].mean()
out = pred / "score"
out.mkdir(exist_ok=True)
well.to_csv(out / "per_well.csv", index=False)
run.to_csv(out / "runs.csv", index=False)
test = run[run.split == "test"].drop(columns="split")
L = [f"# Score of `{a.name}` (scripts/37_bench_package.py score)", "",
f"{len(well.groupby(['split', *RUN]))} predictions; test split: {len(test)} runs in {test.groupby(CELL).ngroups} cells.",
"Rules: protocol_bench (improves: band RMSE ≤ 0.90 × best point tie or band PCC ≥ +0.05; cell_pass: ≥ 4/5 seeds "
"and > 1/2 of realizations; better: lower band RMSE in ≥ 4/5 seeds and > 1/2 of realizations).", ""]
if len(test):
rules, pairs, means = rule_tables(test, ref, a.name)
for f, df in (("rule_point_ties.csv", rules), ("pairs.csv", pairs), ("cells.csv", means)):
df.to_csv(out / f, index=False)
complete = lambda df: df[(df.n_rid == 8) & (df.n_seed == 5)] if len(df) else df
if len(rules):
rc = complete(rules)
L += [f"- H2a cell rule vs best point tie: {int(rules.cell_pass.sum())}/{len(rules)} cells pass "
f"({int(rc.cell_pass.sum())}/{len(rc)} among complete cells: 8 realizations × 5 seeds)."]
for m in ("B3d-Sa", "M2-Sa", "PM2", "BK2", "Oracle"):
q = pairs[pairs.reference == m] if len(pairs) else pairs
if len(q):
L += [f"- better than {m}: {int(q.better.sum())}/{len(q)} cells; median ratio {q.ratio.median():.3f}."]
L += ["", "| setting | c | N | n_rid × n_seed | ratio vs best point tie (best) | cell_pass | ratio vs B3d-Sa |",
"|---|---|---|---|---|---|---|"]
rr = rules.set_index(CELL) if len(rules) else None
pb = pairs[pairs.reference == "B3d-Sa"].set_index(CELL) if len(pairs) else None
for row in means.itertuples():
k = (row.setting, row.c, row.n_train)
h = f"{rr.loc[k, 'ratio']:.3f} ({rr.loc[k, 'best']})" if rr is not None and k in rr.index else "—"
cp = str(bool(rr.loc[k, "cell_pass"])) if rr is not None and k in rr.index else "—"
b = f"{pb.loc[k, 'ratio']:.3f}" if pb is not None and k in pb.index else "—"
L.append(f"| {row.setting} | {row.c:g} | {row.n_train} | {row.n_rid} × {row.n_seed} | {h} | {cp} | {b} |")
dev = run[run.split == "dev"]
if len(dev):
L += ["", f"Dev split: {len(dev)} runs, metrics only (runs.csv); dev labels may be used for design."]
(out / "score.md").write_text("\n".join(L) + "\n")
print("\n".join(L[:12]))
print(f"→ {out}")
# ---------------------------------------------------------------- self-test
SELFTEST = [ # (setting, train dir relative to outputs/, tag suffix, c, method)
("R10", "bench/s1/train/R10/cells", "", 1.5, "B3d-Sa"),
("R10__wv_L1", "bench/s2/train/R10__wv_L1/cells", "", 1.0, "B3d-Sa"),
("R10", "p2r/train/R10/cells", "", 1.0, "B3d-Sa"),
("R10__s8d16", "bench/s8/train/R10/cells", "_d16", 1.0, "BK2"),
]
def selftest(a) -> None:
p = load_protocol()
pkg = Path(a.out)
sub = pkg / "selftest_submission"
shutil.rmtree(sub, ignore_errors=True)
bud, name = p["training"]["budgets"], "SelfTest"
worst_y = 0.0
for setting, d, suf, c, m in SELFTEST:
for N in (4, 16):
for rid in p["grid"]["realizations"]:
with np.load(outputs_dir() / d / f"r{rid}_c{c:g}_n{N}{suf}.npz") as z, \
np.load(pkg / "truth" / "test" / setting / f"r{rid}_c{c:g}.npz") as t:
worst_y = max(worst_y, float(np.abs(z["y_true"] - t["y_test"]).max()))
if not (z["test_wells"] == t["test_names"]).all():
raise SystemExit(f"{setting} r{rid}: test well order differs")
for seed in p["grid"]["seeds"]:
f = sub / "test" / setting / f"r{rid}_c{c:g}_n{N}_s{seed}.npz"
f.parent.mkdir(parents=True, exist_ok=True)
k = f"{m}/s{seed}/b{bud[m]}"
np.savez(f, mu=z[f"{k}/mu"], sigma=z[f"{k}/sigma"])
score(argparse.Namespace(out=str(pkg), pred=str(sub), name=name))
ref = pd.read_csv(pkg / "reference" / "runs.csv.gz")
got = pd.read_csv(sub / "score" / "runs.csv")
rules = pd.read_csv(sub / "score" / "rule_point_ties.csv")
pairs = pd.read_csv(sub / "score" / "pairs.csv")
msg, ok = [f"max |y_true(runner, float32) − y_test(package)| = {worst_y:.2e} p.u."], worst_y < 1e-4
for setting, _, _, c, m in SELFTEST:
g = got[(got.setting == setting) & (got.c == c)].set_index(["n_train", "rid", "seed"])
r = ref[(ref.setting == setting) & (ref.c == c) & (ref.method == m)].set_index(["n_train", "rid", "seed"]).reindex(g.index)
dm = float(np.abs(g.band_rmse - r.band_rmse).max())
ok &= dm < 1e-4 and len(g) == 2 * 8 * 5
line = f"{setting} c={c:g} copy of {m}: {len(g)} runs, max |Δ band RMSE| = {dm:.1e}"
cell = ref[(ref.setting == setting) & (ref.c == c)]
for N in (4, 16):
cr = cell[cell.n_train == N]
if set(S.POINT_TIES) <= set(cr.method):
want = S.h2a_cells(cr, m, S.POINT_TIES, np.random.default_rng(0), N_BOOT).iloc[0]
have = rules[(rules.setting == setting) & (rules.c == c) & (rules.n_train == N)].iloc[0]
same = want.best == have.best and bool(want.cell_pass) == bool(have.cell_pass) and abs(want.ratio - have.ratio) < 1e-4
line += f"; N={N} ratio {have.ratio:.4f} vs {want.ratio:.4f} ({want.best}, pass {bool(want.cell_pass)})"
else:
want = S.pair(cr, m, "PM2", np.random.default_rng(0), N_BOOT)
have = pairs[(pairs.setting == setting) & (pairs.c == c) & (pairs.n_train == N) & (pairs.reference == "PM2")].iloc[0]
same = bool(want["better"]) == bool(have.better) and abs(want["ratio"] - have.ratio) < 1e-4
line += f"; N={N} ratio vs PM2 {have.ratio:.4f} vs {want['ratio']:.4f}"
ok &= same
msg.append(line)
print("\n".join(msg))
(pkg / "selftest.json").write_text(json.dumps({"pass": bool(ok), "checks": msg}, indent=1))
shutil.rmtree(sub)
if not ok:
raise SystemExit("selftest FAILED")
print("selftest PASS")
def main() -> None:
ap = argparse.ArgumentParser(description=__doc__.split("\n")[0])
sp = ap.add_subparsers(dest="cmd", required=True)
g = sp.add_parser("generate")
g.add_argument("--split", nargs="+", default=["test", "dev"], choices=["test", "dev"])
g.add_argument("--update-manifest", action="store_true")
g.add_argument("--skip-lock-check", action="store_true")
s = sp.add_parser("score")
s.add_argument("--pred", required=True)
s.add_argument("--name", required=True)
for name in ("tables", "selftest", "check"):
sp.add_parser(name)
for x in sp.choices.values():
x.add_argument("--out", default=str(PKG))
a = ap.parse_args()
{"generate": generate, "tables": tables, "score": score, "selftest": selftest, "check": check}[a.cmd](a)
if __name__ == "__main__":
main()

169
scripts/38_bench_figures.py Normal file
View File

@@ -0,0 +1,169 @@
"""Manuscript figures of Experiment 3 (protocol_bench, phase P6), drawn from the locked summary outputs only.
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/38_bench_figures.py [--only bench_s1,bench_s8] [--flipband]
Outside the protocol_bench code hash (like scripts/36 and 37); checks the lock first and never writes under outputs/.
Reads outputs/bench/summary/s1_cells.csv (S1 phase diagram) and outputs/bench/summary/s8_transfer_curves.json; the
S8 usable band (Oracle cross-spectrum ≥ 0.1 × its maximum above 6 Hz) is recomputed from the S8 prediction files
exactly as ml_porosity/benchmark/summary.py does, because the curves file does not store it.
Style, palette and output folder are those of scripts/22_paper_figures.py (→ paper/figures/{bench_s1,bench_s8}.pdf).
--flipband prints (stdout only) the Section 6.5 S8 comparison: mean cos(πfΔ), mean cos²(πfΔ) (Corollary 3, the λ → 0
transfer of the equal-weight two-member bank, which contains the true warp but is not calibrated) and the measured
PM2/BK2/HM2 transfer over the usable frequencies of the band 1/(2Δ) < f < 3/(2Δ), for every S8 cell.
"""
from __future__ import annotations
import argparse
import importlib.util
import json
import numpy as np
import pandas as pd
from matplotlib.lines import Line2D
from matplotlib.patches import Rectangle
from ml_porosity.benchmark import summary as S
from ml_porosity.benchmark.cells import Cell, bench_root, train_paths
from ml_porosity.benchmark.protocol import freeze, load_protocol
from ml_porosity.eval import figstyle as fs
from ml_porosity.paths import REPO_ROOT
_spec = importlib.util.spec_from_file_location("s22", REPO_ROOT / "scripts" / "22_paper_figures.py")
F = importlib.util.module_from_spec(_spec) # style(), save(), text_on(), WIDTH of the other manuscript figures
_spec.loader.exec_module(F)
plt = F.plt
SUMMARY = bench_root(dev=False) / "summary"
REGIMES = ["R10", "R0", "Rm5", "R0h", "R10tb"]
# ---------------------------------------------------------------- Fig. S1 phase diagram (Section 6.5)
def bench_s1() -> None:
d = pd.read_csv(SUMMARY / "s1_cells.csv")
cs, Ns = sorted(d.c.unique()), sorted(d.n_train.unique())
norm, cmap = fs.diverging_norm(0.65, 1.0, 1.15), fs.DIVERGING
rows = [("pm_best", r"B3d-Sa / best point tie"), ("m2_pm", r"M2-Sa / B3d-Sa")]
fig, axes = plt.subplots(2, len(REGIMES), figsize=(F.WIDTH, 3.55), sharex=True, sharey=True, layout="constrained")
for i, (k, lab) in enumerate(rows):
for j, reg in enumerate(REGIMES):
ax = axes[i, j]
t = d[d.regime == reg].set_index(["c", "n_train"])
Z = t[f"{k}_ratio"].unstack("n_train").reindex(index=cs, columns=Ns).to_numpy()
im = ax.imshow(Z, cmap=cmap, norm=norm, origin="lower", aspect="auto")
for a, c in enumerate(cs):
for b, N in enumerate(Ns):
r = t.loc[(c, N)]
txt = f"{r[k + '_ratio']:.2f}"
ax.text(b, a, txt if r[k + "_better"] else f"({txt})", ha="center", va="center", fontsize=6,
color=F.text_on(cmap(norm(r[k + "_ratio"]))))
if k == "m2_pm" and r.sigma_post_ms >= 1.5:
ax.add_patch(Rectangle((b - 0.42, a - 0.42), 0.84, 0.84, fill=False, ec=fs.INK, lw=0.6))
ax.set_xticks(range(len(Ns)), [str(n) for n in Ns])
ax.set_yticks(range(len(cs)), [f"{c:g}" for c in cs])
ax.grid(False)
for s in ax.spines.values():
s.set_visible(False)
ax.tick_params(length=0)
ax.set_title(f"({'ab'[i]}{j + 1}) {reg}", loc="left", fontsize=8, color=fs.INK, pad=3)
if i == 1:
ax.set_xlabel(r"wells $N$")
if j == 0:
ax.set_ylabel(r"drift factor $c$")
cb = fig.colorbar(im, ax=axes[i, :], shrink=0.95, pad=0.01, extend="both")
cb.ax.axhline(1.0, color=fs.INK, lw=0.9)
cb.set_label(lab, color=fs.INK2, fontsize=7)
cb.outline.set_visible(False)
F.save(fig, "bench_s1")
# ---------------------------------------------------------------- Fig. S8 two-mode transfer functions (Section 6.5)
def oracle_spectrum(p: dict, reg: str, d: float, N: int) -> tuple[np.ndarray, np.ndarray]:
"""Usable-frequency mask of an S8 cell, as in summary.s8 (Oracle cross-spectrum pooled over rids/seeds/wells)."""
f = np.fft.rfftfreq(S.NFFT, 4.0 / 1000.0)
b = S.study_budgets(p, "S8")["Oracle"]
so = np.zeros(len(f))
for rid in p["grid"]["realizations"]:
cell = Cell("S8", reg, None, 1.0, int(N), int(rid), tuple(p["studies"]["S8"]["methods"]), posterior="none",
delta_ms=float(d))
with np.load(train_paths(cell, bench_root(dev=False))["npz"]) as z:
Y = z["y_true"].astype(float)
for k in (k for k in z.files if k.startswith("Oracle/s") and k.endswith(f"/b{b}/mu")):
so += S.cross_spectrum(Y, z[k].astype(float))
band = f >= 6.0
return f, band & (so >= 0.1 * so[band].max())
STYLE_S8 = {"PM2": dict(lw=1.3, marker="o", ms=1.6), "BK2": dict(lw=1.8, marker="o", ms=2.0),
"HM2": dict(lw=0.9, ls=(0, (3, 1.5)))} # BK2 and HM2 nearly coincide: HM2 dashed on top
def bench_s8(N: int = 16) -> None:
p = load_protocol()
curves = [c for c in json.loads((SUMMARY / "s8_transfer_curves.json").read_text()) if c["n_train"] == N]
deltas = sorted({c["delta_ms"] for c in curves})
cols = {"PM2": fs.ORANGE, "BK2": fs.BLUE, "HM2": fs.AQUA}
fig, axes = plt.subplots(2, len(deltas), figsize=(F.WIDTH, 3.5), sharey=True, layout="constrained")
for i, reg in enumerate(["R10", "Rm5"]):
for j, d in enumerate(deltas):
ax = axes[i, j]
f, use = oracle_spectrum(p, reg, d, N)
fmax = f[use].max()
lo, hi = 1000.0 / (2 * d), 3000.0 / (2 * d)
ax.axvspan(lo, min(hi, fmax + 5), color=fs.GRID, alpha=0.7, lw=0)
ax.axhline(0.0, color=fs.AXIS, lw=0.8)
ax.plot(f, np.cos(np.pi * f * d / 1000.0), color=fs.INK2, lw=0.9, ls="--")
for m, col in cols.items():
c = next(c for c in curves if c["regime"] == reg and c["delta_ms"] == d and c["method"] == m)
H = np.where(use, np.asarray(c["H"], float), np.nan)
ax.plot(f, H, color=col, **STYLE_S8[m])
ax.set(xlim=(0, fmax + 5), ylim=(-1.4, 1.6))
ax.set_title(f"({'ab'[i]}{j + 1}) {reg}, " + rf"$\Delta = {d:g}$ ms", loc="left", fontsize=8, color=fs.INK, pad=3)
if i == 1:
ax.set_xlabel("frequency (Hz)")
if j == 0:
ax.set_ylabel(r"transfer $\hat H(f)$ vs. Oracle")
handles = [Line2D([], [], color=col, label=m, **STYLE_S8[m]) for m, col in cols.items()]
handles.append(Line2D([], [], color=fs.INK2, lw=0.9, ls="--", label=r"$\cos(\pi f \Delta)$"))
fig.legend(handles=handles, loc="outside lower center", ncol=4)
F.save(fig, "bench_s8")
def flipband() -> None:
p = load_protocol()
curves = json.loads((SUMMARY / "s8_transfer_curves.json").read_text())
print("regime delta_ms N n_freq mean_cos mean_cos2 PM2 BK2 HM2")
for reg in ["R10", "Rm5"]:
for d in sorted({c["delta_ms"] for c in curves}):
for N in sorted({c["n_train"] for c in curves}):
f, use = oracle_spectrum(p, reg, d, N)
fl = use & (f > 1000.0 / (2 * d)) & (f < 3000.0 / (2 * d))
if not fl.any():
print(f"{reg:6s} {d:8g} {N:2d} {0:6d} (no usable frequency in the band)")
continue
c = np.cos(np.pi * f[fl] * d / 1000.0)
H = {m: np.asarray(next(x for x in curves if x["regime"] == reg and x["delta_ms"] == d
and x["n_train"] == N and x["method"] == m)["H"], float)[fl].mean()
for m in ("PM2", "BK2", "HM2")}
print(f"{reg:6s} {d:8g} {N:2d} {int(fl.sum()):6d} {c.mean():8.3f} {(c ** 2).mean():9.3f} "
+ " ".join(f"{H[m]:5.3f}" for m in ("PM2", "BK2", "HM2")))
FIGURES = {"bench_s1": bench_s1, "bench_s8": bench_s8}
def main() -> None:
ap = argparse.ArgumentParser()
ap.add_argument("--only", default="", help="comma-separated subset of " + ",".join(FIGURES))
ap.add_argument("--flipband", action="store_true", help="print the S8 flip-band table instead of drawing")
args = ap.parse_args()
freeze(check=True)
if args.flipband:
flipband()
return
F.style()
for k in (args.only.split(",") if args.only else FIGURES):
FIGURES[k]()
if __name__ == "__main__":
main()

627
scripts/39_repro_package.py Normal file
View File

@@ -0,0 +1,627 @@
"""Reproduction package of the manuscript (phase P5): derived-data archives, a manifest and a clean-room check.
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/39_repro_package.py build [--out DIR] [--dry-run]
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/39_repro_package.py check --root DIR
CUDA_VISIBLE_DEVICES= .venv/bin/python scripts/39_repro_package.py verify [--out DIR] [--work DIR] [--only STEP …] [--keep]
.venv/bin/python scripts/39_repro_package.py code --rev REV [--out DIR]
DIR defaults to outputs/repro (gitignored). Documentation for readers: repro/README.md.
build Selects files of outputs/ by the first matching rule of RULES (anything without a rule stays out) and writes
one deterministic tar.gz per archive of ARCHIVES (sorted members, fixed mtime and owner, gzip mtime 0) to DIR,
and repro/MANIFEST.json (tracked in git): per archive its licence, size and sha256, per file its archive,
producing script, size and sha256 (exact bytes). Members are stored as outputs/<path>, so extracting an
archive in the repository root restores the original layout. The archives split by data licence (F3-derived
CC BY-SA 3.0; Volve-derived CC BY-NC-SA 4.0; Teapot, licence to be verified) and, within F3, by size.
--dry-run prints the selection and sizes without writing.
check Recomputes the sha256 of every manifest file under DIR (a tree in which the archives were extracted, i.e.
DIR/outputs/...) and reports missing and differing files.
verify Clean-room check that the archives and the code suffice. Copies the code (git ls-files -co --exclude-standard,
without logs/, refs/, code_thesis/, outputs_thesis/, .agents/; the tracked F3 well files under data/ are part
of the repository) into WORK/repo, extracts the archives there, deletes the copied paper figures, and runs the
steps of STEPS with WORK/repo first on PYTHONPATH (so `ml_porosity` and the default outputs/ and data/ roots
are those of the copy; no SEG-Y, Volve or Teapot raw data). A sitecustomize audit hook logs the files each
step opens and flags any read of the original repository. Afterwards every file a step rewrote is compared
with the original: by sha256, and, if the bytes differ, by value (csv, json, npz, md); paper figures are
rasterised with Ghostscript and compared pixel by pixel with paper/figures/; stdout steps are compared with the
same command run on the original outputs. → repro/verify_report.md (git) and WORK/verify.json.
WORK defaults to DIR/work and is deleted afterwards unless --keep.
code git archive of REV → DIR/ML-Porosity_code_<rev>.tar.gz; refuses when tracked files differ from REV.
Outside every protocol lock (protocol_bench hashes ml_porosity/ and scripts/34 only). Nothing here trains, edits a
locked output or touches the original outputs/: verify writes only inside WORK.
"""
from __future__ import annotations
import argparse
import difflib
import fnmatch
import gzip
import hashlib
import io
import json
import os
import shutil
import subprocess
import sys
import tarfile
import time
from datetime import datetime, timezone
from pathlib import Path
import numpy as np
import pandas as pd
from ml_porosity.paths import REPO_ROOT, outputs_dir
DOC = REPO_ROOT / "repro"
MANIFEST = DOC / "MANIFEST.json"
MTIME = int(datetime(2026, 11, 2, tzinfo=timezone.utc).timestamp()) # fixed member mtime of the archives
F3 = "CC-BY-SA-3.0"
VOLVE = "CC-BY-NC-SA-4.0"
TEAPOT = "CC0-1.0 (as recorded in the project notes; verify on the Texas Data Repository page before deposit)"
ARCHIVES = {
"f3_results": (F3, "Summaries, verdicts, post hoc tables, run-level metric tables and the small derived inputs "
"behind every number of the manuscript; F3-derived and synthetic (D2 generator on F3 geometry)"),
"f3_predictions": (F3, "Saved test predictions of the registered runs (P1, P2, P2r, T2, protocol_bench, P3) and "
"the P2r SMC particles of the S4 cells, which the protocol_bench lock hashes"),
"f3_volume": (F3, "Descriptive F3 porosity volume of the 20 P3 deployment models (649 interior inlines)"),
"volve": (VOLVE, "Volve-derived well data, P4 summaries and post hoc tables, and the applicability tables that "
"combine F3 and Volve (licence of the combination to be confirmed by the authors)"),
"teapot": (TEAPOT, "Teapot Dome inventory (headers and curve coverage) and pilot P-a (knots, picks); no porosity"),
}
# (pattern relative to outputs/, archive, producer). First match wins; fnmatch `*` also matches `/`; archive None
# excludes. Files that match no rule stay out (large SMC particle files, training checkpoints, P3/P4 training runs,
# smoke runs, superseded backups, the separately deposited benchmark package outputs/bench/package, and outputs/p4x,
# which the manuscript never uses).
RULES = [
# F3 audit, tie and well inputs (historical artifacts of scripts 01, 02, 04: never rerun, hashes protected)
("td_qc.csv", "f3_results", "scripts/02_td_qc.py"),
("tie_qc.csv", "f3_results", "scripts/04_wavelet_tie.py"),
("marker_vs_horizon.csv", "f3_results", "scripts/04_wavelet_tie.py"),
("tie_local_shifts.csv", "f3_results", "scripts/04_wavelet_tie.py"),
("wavelets.npz", "f3_results", "scripts/04_wavelet_tie.py"),
("f3_wells.npz", "f3_results", "scripts/01_build_wells.py"),
("f3_wells_summary.json", "f3_results", "scripts/01_build_wells.py"),
# P1 LOWO baselines
("p1/*.npz", "f3_predictions", "scripts/05_lowo.py"),
("p1/*", "f3_results", "scripts/05_lowo.py, scripts/06_summarize_p1.py"),
# D2 generator QC and horizon cache, warp prior
("d2/qc.json", "f3_results", "scripts/10_build_d2.py"),
("d2/horizon_grid.npz", "f3_results", "ml_porosity/data/synth_d2.py (horizon cache)"),
("p2/warp_prior_f3.json", "f3_results", "scripts/09_fit_warp_prior_f3.py"),
# P2 (protocol_p2)
("p2/summary/*", "f3_results", "scripts/13_summarize_p2.py"),
("p2/h1/*.npz", "f3_predictions", "scripts/12_h1_blur.py"),
("p2/h1/*", "f3_results", "scripts/12_h1_blur.py"),
("p2/main/*.npz", "f3_predictions", "scripts/11_run_d2.py --main"),
("p2/main/*", "f3_results", "scripts/11_run_d2.py --main"),
("p2/dev/*.npz", "f3_predictions", "scripts/11_run_d2.py --dev"),
("p2/dev/*", "f3_results", "scripts/11_run_d2.py --dev"),
("p2/diag/train/budgets.json", "f3_results", "scripts/15_diag_train.py (P2r dev budgets)"),
("p2/diag/p2rdev/*", "f3_results", "scripts/17_summarize_p2r_dev.py"),
("p2/diag/f3_posterior/*.npz", None, ""),
("p2/diag/f3_posterior/*", "f3_results", "scripts/16_f3_posterior.py"),
("p2/diag/*.csv", "f3_results", "scripts/run_p2r_dev.sh (dev realizations 900/901)"),
("p2/diag/*.json", "f3_results", "scripts/run_p2r_dev.sh (dev realizations 900/901)"),
("d1/*", "f3_results", "scripts/08_d1_label_check.py"),
# P2r (protocol_p2r) and its post hoc analyses
("p2r/summary/*", "f3_results", "scripts/18_summarize_p2r.py"),
("p2r/posthoc/*", "f3_results", "scripts/31_p2r_posthoc.py"),
("p2r/train/*.npz", "f3_predictions", "scripts/run_p2r_main.sh (scripts/15_diag_train.py)"),
("p2r/train/*", "f3_results", "scripts/run_p2r_main.sh (scripts/15_diag_train.py)"),
("p2r/posterior/*.csv", "f3_results", "scripts/run_p2r_main.sh (scripts/14_diag_posterior.py)"),
("p2r/posterior/*.json", "f3_results", "scripts/run_p2r_main.sh (scripts/14_diag_posterior.py)"),
("t2/*.npz", "f3_predictions", "scripts/32_t2_mechanism.py"),
("t2/*", "f3_results", "scripts/32_t2_mechanism.py"),
("t3/*", "f3_results", "scripts/27_t3_power.py"),
("t4/*", "f3_results", "scripts/30_t4_coverage.py"),
# protocol_bench (Experiment 3)
("bench/summary/verdict_final.*", "f3_results", "scripts/36_bench_verdicts.py"),
("bench/summary/s3_h2a_stated.csv", "f3_results", "scripts/36_bench_verdicts.py"),
("bench/summary/*", "f3_results", "scripts/34_run_bench.py summarize"),
("bench/repro/comparison.json", "f3_results", "scripts/34_run_bench.py repro"),
("bench/repro/*", "f3_predictions", "scripts/34_run_bench.py repro"),
("bench/dev/calibration.*", "f3_results", "scripts/35_bench_calibration.py"),
("bench/dev/generator_*", "f3_results", "scripts/33_bench_generator_qc.py"),
("bench/dev/smc_qc_rid*.json", "f3_results", "scripts/33_bench_generator_qc.py --smc"),
("bench/dev/budgets_tcn.json", "f3_results", "scripts/34_run_bench.py dev-budgets"),
("bench/dev/progress.json", None, ""),
("bench/dev/summary/*", "f3_results", "scripts/34_run_bench.py summarize --dev"),
("bench/dev/*.csv", "f3_results", "scripts/34_run_bench.py posterior train --dev"),
("bench/dev/*.json", "f3_results", "scripts/34_run_bench.py posterior train --dev"),
("bench/s[12348]/train/*.npz", "f3_predictions", "scripts/34_run_bench.py train"),
("bench/s[12348]/train/*.csv", "f3_results", "scripts/34_run_bench.py train"),
("bench/s[12348]/train/*.json", "f3_results", "scripts/34_run_bench.py train"),
("bench/posterior/*.csv", "f3_results", "scripts/34_run_bench.py posterior"),
("bench/posterior/*.json", "f3_results", "scripts/34_run_bench.py posterior"),
# P3 F3 field test (protocol_f3; reproduce from tag protocol-f3)
("p3/summary/predictions.npz", "f3_predictions", "scripts/20_summarize_f3.py"),
("p3/summary/*", "f3_results", "scripts/20_summarize_f3.py"),
("p3/diagnostics/*.npz", "f3_predictions", "scripts/19_run_f3.py diagnostics"),
("p3/diagnostics/*", "f3_results", "scripts/19_run_f3.py diagnostics"),
("p3/registration/*.npz", "f3_predictions", "scripts/19_run_f3.py register"),
("p3/registration/*.json", "f3_results", "scripts/19_run_f3.py register"),
("p3/volume/metadata.json", "f3_results", "scripts/21_predict_f3.py"),
("p3/volume/state.json", "f3_results", "scripts/21_predict_f3.py"),
("p3/volume/*", "f3_volume", "scripts/21_predict_f3.py"),
("p3/completion_checks.json", "f3_results", "operations/check_f3_completion.py"),
("p3/volume_recovery.json", "f3_results", "operations/resume_f3_volume.py"),
("p3/deployment.json", "f3_results", "scripts/21_predict_f3.py"),
("p3/benchmark.json", "f3_results", "scripts/19_run_f3.py benchmark"),
("p3/registration_benchmark.json", "f3_results", "scripts/19_run_f3.py benchmark"),
("p3/review_checks.json", "f3_results", "scripts/19_run_f3.py (review checks)"),
# Volve (P4, protocol_volve; reproduce from tag protocol-volve) and the applicability study
("volve/*", "volve", "scripts/07_volve_interp_qc.py, scripts/23_build_volve_wells.py"),
("p4/summary/*", "volve", "scripts/24_run_volve.py summarize"),
("p4/posthoc/*", "volve", "scripts/25_p4_posthoc.py"),
("p4/registration/*.json", "volve", "scripts/24_run_volve.py register"),
("p4/benchmark.json", "volve", "scripts/24_run_volve.py benchmark"),
("applicability/*", "volve", "scripts/26_applicability.py"),
# Teapot Dome (stopped at T0 and pilot P-a)
("teapot/inventory/*", "teapot", "python -P scripts/28_teapot_inventory.py"),
("teapot/pilot_pa/*", "teapot", "python -P scripts/29_teapot_pilot.py"),
]
S4_PRODUCER = "scripts/run_p2r_main.sh (scripts/14_diag_posterior.py); hashed by the protocol_bench lock"
# Clean-room steps: (name, argv after the interpreter, kind). kind: "files" (compare rewritten outputs), "figures"
# (also compare paper/figures/<name>.pdf), "stdout" (compare stdout with the same command on the original outputs).
STEPS = [
("p1_summary", ["scripts/06_summarize_p1.py"], "files"),
("p2_summary", ["scripts/13_summarize_p2.py", "--mode", "main"], "files"),
("p2r_summary", ["scripts/18_summarize_p2r.py"], "files"),
("p2r_posthoc", ["scripts/31_p2r_posthoc.py"], "files"),
("t4_coverage", ["scripts/30_t4_coverage.py"], "files"),
("t3_power", ["scripts/27_t3_power.py"], "files"),
("bench_summarize", ["scripts/34_run_bench.py", "summarize"], "files"),
("bench_verdicts", ["scripts/36_bench_verdicts.py"], "files"),
("bench_tables", ["scripts/37_bench_package.py", "tables", "--out", "outputs/bench/package"], "files"),
("figures_main", ["scripts/22_paper_figures.py"], "figures"),
("figures_bench", ["scripts/38_bench_figures.py"], "figures"),
("s8_flipband", ["scripts/38_bench_figures.py", "--flipband"], "stdout"),
]
# Files outside outputs/ that a step rewrites in the repository, compared with the original repository files.
REPO_OUTPUTS = {"bench_tables": ["benchmark/reference/cells.csv", "benchmark/reference/main_table.md"]}
NO_CODE = ("logs/", "refs/", "code_thesis/", "outputs_thesis/", ".agents/")
SITECUSTOMIZE = '''
import os, sys
_log = os.environ.get("REPRO_AUDIT_LOG")
if _log:
_W = os.O_WRONLY | os.O_RDWR | os.O_CREAT | os.O_APPEND
def _hook(event, args, _f=open(_log, "a", buffering=1), _seen=set()):
if event == "open" and args and isinstance(args[0], (str, bytes, os.PathLike)):
try:
p = os.path.abspath(os.fsdecode(args[0]))
except Exception:
return
mode = args[1] if len(args) > 1 else None
flags = args[2] if len(args) > 2 and isinstance(args[2], int) else 0
w = any(c in mode for c in "wax+") if isinstance(mode, str) else bool(flags & _W)
key = ("W " if w else "R ") + p
if key not in _seen:
_seen.add(key)
_f.write(key + "\\n")
sys.addaudithook(_hook)
'''
# ---------------------------------------------------------------- selection and manifest
def sha256(path: Path, bufsize: int = 1 << 22) -> str:
h = hashlib.sha256()
with open(path, "rb") as f:
while b := f.read(bufsize):
h.update(b)
return h.hexdigest()
def s4_reference_files() -> list[Path]:
from ml_porosity.benchmark.protocol import load_protocol, p2r_reference_files
return [f for f in p2r_reference_files(load_protocol()) if "/posterior/" in f.as_posix()]
def select(root: Path) -> list[dict]:
"""Every file of the package: path (outputs/...), archive, producer."""
s4 = {f.resolve() for f in s4_reference_files()}
rows, seen = [], set()
for f in sorted(root.rglob("*")):
if not f.is_file() or f.is_symlink():
continue
rel = f.relative_to(root).as_posix()
if f.resolve() in s4:
rows.append({"path": f"outputs/{rel}", "archive": "f3_predictions", "producer": S4_PRODUCER})
seen.add(f.resolve())
continue
if rel.startswith(("p2r/posterior/", "bench/posterior/", "bench/dev/")) and rel.endswith(".npz"):
continue # other particles and dev predictions: no table reads them
for pat, arc, prod in RULES:
if fnmatch.fnmatchcase(rel, pat):
if arc:
rows.append({"path": f"outputs/{rel}", "archive": arc, "producer": prod})
break
if missing := s4 - seen:
raise FileNotFoundError(f"{len(missing)} S4 reference files missing under {root}")
return rows
def tar_gz(path: Path, members: list[tuple[str, Path]]) -> None:
tmp = path.with_suffix(path.suffix + ".part")
with open(tmp, "wb") as raw, gzip.GzipFile(filename="", mode="wb", fileobj=raw, mtime=0, compresslevel=6) as gz, \
tarfile.open(fileobj=gz, mode="w", format=tarfile.PAX_FORMAT) as tar:
for arc, src in sorted(members):
ti = tarfile.TarInfo(arc)
ti.size, ti.mtime, ti.mode = src.stat().st_size, MTIME, 0o644
ti.uid = ti.gid = 0
ti.uname = ti.gname = ""
with open(src, "rb") as f:
tar.addfile(ti, f)
tmp.replace(path)
def build(a) -> None:
root, out = outputs_dir(), Path(a.out)
rows = select(root)
for r in rows:
r["bytes"] = (root / r["path"][len("outputs/"):]).stat().st_size
df = pd.DataFrame(rows)
print(df.groupby("archive").agg(files=("path", "size"), MB=("bytes", lambda b: round(b.sum() / 1e6, 1))).to_string())
if a.dry_run:
for arc, g in df.groupby("archive"):
top = g.assign(top=g.path.str.split("/").str[1:3].str.join("/")).groupby("top").bytes.agg(["size", "sum"])
print(f"\n{arc}\n" + (top.assign(MB=(top["sum"] / 1e6).round(2)).drop(columns="sum")).to_string())
return
out.mkdir(parents=True, exist_ok=True)
t0 = time.time()
for r in rows:
r["sha256"] = sha256(root / r["path"][len("outputs/"):])
archives = {}
for arc, (lic, desc) in ARCHIVES.items():
sel = [r for r in rows if r["archive"] == arc]
name = f"ML-Porosity_derived_{arc}.tar.gz"
tar_gz(out / name, [(r["path"], root / r["path"][len("outputs/"):]) for r in sel])
archives[arc] = {"file": name, "licence": lic, "description": desc, "n_files": len(sel),
"bytes_uncompressed": int(sum(r["bytes"] for r in sel)),
"bytes": (out / name).stat().st_size, "sha256": sha256(out / name)}
print(f"wrote {out / name}: {len(sel)} files, {archives[arc]['bytes'] / 1e6:.1f} MB ({time.time() - t0:.0f} s)")
DOC.mkdir(exist_ok=True)
man = {"package": "ML-Porosity derived data for the manuscript (reproduction package, phase P5)",
"layout": "members are outputs/<path>; extract each archive in the repository root",
"hash": "sha256 of the exact file bytes", "archives": archives,
"files": [{k: r[k] for k in ("path", "archive", "producer", "bytes", "sha256")} for r in rows]}
MANIFEST.write_text(json.dumps(man, indent=1, ensure_ascii=False) + "\n", encoding="utf-8")
print(f"wrote {MANIFEST} ({len(rows)} files)")
def check_tree(root: Path, man: dict) -> dict:
res = {"ok": [], "missing": [], "differs": []}
for r in man["files"]:
f = root / r["path"]
if not f.exists():
res["missing"].append(r["path"])
elif f.stat().st_size != r["bytes"] or sha256(f) != r["sha256"]:
res["differs"].append(r["path"])
else:
res["ok"].append(r["path"])
return res
def check(a) -> None:
man = json.loads(MANIFEST.read_text(encoding="utf-8"))
res = check_tree(Path(a.root), man)
print(f"{len(res['ok'])}/{len(man['files'])} files match; {len(res['missing'])} missing, {len(res['differs'])} differ")
for k in ("missing", "differs"):
for p in res[k][:20]:
print(f" {k}: {p}")
if res["missing"] or res["differs"]:
raise SystemExit(1)
# ---------------------------------------------------------------- comparison helpers
def _num_equal(x, y, tol=1e-12) -> float:
"""Max relative difference of two numeric arrays (NaN-aware); inf if shapes or NaN patterns differ."""
x, y = np.asarray(x, float), np.asarray(y, float)
if x.shape != y.shape or not np.array_equal(np.isnan(x), np.isnan(y)):
return float("inf")
m = ~np.isnan(x)
if not m.any():
return 0.0
return float(np.max(np.abs(x[m] - y[m]) / np.maximum(1.0, np.abs(y[m]))))
def _json_diff(a, b, path="", out=None, tol=1e-9):
out = [] if out is None else out
if isinstance(a, dict) and isinstance(b, dict):
for k in sorted(set(a) | set(b), key=str):
if k not in a or k not in b:
out.append(f"{path}/{k}: only in {'new' if k in a else 'original'}")
else:
_json_diff(a[k], b[k], f"{path}/{k}", out, tol)
elif isinstance(a, list) and isinstance(b, list) and len(a) == len(b):
for i, (x, y) in enumerate(zip(a, b)):
_json_diff(x, y, f"{path}[{i}]", out, tol)
elif isinstance(a, (int, float)) and isinstance(b, (int, float)) and not isinstance(a, bool):
if not (a == b or (np.isnan(a) and np.isnan(b)) or abs(a - b) <= tol * max(1.0, abs(b))):
out.append(f"{path}: {b!r} → {a!r}")
elif a != b:
out.append(f"{path}: {str(b)[:60]!r} → {str(a)[:60]!r}")
return out
def compare_file(new: Path, orig: Path, root: Path | None = None) -> dict:
"""identical (bytes) | equal (values within 1e-9 relative, or bytes equal once the clean-room root `root` is
replaced by the original repository root) | differs (with a short detail) | missing."""
if not new.exists():
return {"status": "missing", "detail": "not regenerated"}
if sha256(new) == sha256(orig):
return {"status": "identical"}
suf = "".join(new.suffixes[-2:]) if new.name.endswith(".csv.gz") else new.suffix
text = None
if root is not None and suf in (".csv", ".json", ".md", ".txt"):
text = new.read_text(encoding="utf-8").replace(str(root), str(REPO_ROOT))
if text.encode("utf-8") == orig.read_bytes():
return {"status": "equal", "detail": "differs only in the clean-room path"}
try:
if suf in (".csv", ".csv.gz"):
x, y = pd.read_csv(io.StringIO(text) if text is not None else new), pd.read_csv(orig)
if list(x.columns) != list(y.columns) or x.shape != y.shape:
return {"status": "differs", "detail": f"shape/columns {x.shape} vs {y.shape}"}
worst, cols = 0.0, []
for c in x.columns:
if pd.api.types.is_numeric_dtype(x[c]) and pd.api.types.is_numeric_dtype(y[c]):
d = _num_equal(x[c], y[c])
if d > 1e-9:
cols.append(f"{c} ({d:.2g})")
worst = max(worst, d)
elif not x[c].astype(str).equals(y[c].astype(str)):
cols.append(f"{c} (text)")
return ({"status": "equal", "detail": f"max rel. diff {worst:.1e}"} if not cols else
{"status": "differs", "detail": "columns " + ", ".join(cols[:6])})
if suf == ".json":
d = _json_diff(json.loads(text if text is not None else new.read_text(encoding="utf-8")),
json.loads(orig.read_text(encoding="utf-8")))
return {"status": "equal"} if not d else {"status": "differs", "detail": "; ".join(d[:4]) + (f" (+{len(d) - 4})" if len(d) > 4 else "")}
if suf == ".npz":
with np.load(new, allow_pickle=False) as x, np.load(orig, allow_pickle=False) as y:
if sorted(x.files) != sorted(y.files):
return {"status": "differs", "detail": "keys"}
bad = [k for k in x.files if not np.array_equal(x[k], y[k], equal_nan=x[k].dtype.kind == "f")]
return {"status": "equal"} if not bad else {"status": "differs", "detail": "arrays " + ", ".join(bad[:5])}
if suf in (".md", ".txt"):
d = [l for l in difflib.unified_diff(orig.read_text().splitlines(),
(text if text is not None else new.read_text()).splitlines(), lineterm="", n=0)
if l[:1] in "+-" and not l.startswith(("+++", "---"))]
return {"status": "differs", "detail": f"{len(d)} changed lines, e.g. {d[0][:80]!r}" if d else "whitespace"}
except Exception as e: # noqa: BLE001 - reported, not fatal
return {"status": "differs", "detail": f"compare failed: {e}"}
return {"status": "differs", "detail": "bytes differ"}
def raster(pdf: Path, png: Path) -> np.ndarray:
from PIL import Image
subprocess.run(["gs", "-q", "-dSAFER", "-dBATCH", "-dNOPAUSE", "-sDEVICE=png16m", "-r110", f"-sOutputFile={png}",
str(pdf)], check=True)
return np.asarray(Image.open(png).convert("RGB"), dtype=np.int16)
def compare_pdf(new: Path, orig: Path, tmp: Path) -> dict:
x, y = raster(new, tmp / f"{new.stem}_new.png"), raster(orig, tmp / f"{new.stem}_orig.png")
if x.shape != y.shape:
return {"status": "differs", "detail": f"page size {x.shape} vs {y.shape}"}
d = np.abs(x - y).max(axis=2)
frac = float((d > 0).mean())
return {"status": "identical" if frac == 0 else ("equal" if frac < 1e-4 else "differs"),
"detail": f"{100 * frac:.3f}% pixels differ (max {int(d.max())}/255) at 110 dpi"}
# ---------------------------------------------------------------- clean room
def code_files() -> list[str]:
out = subprocess.run(["git", "ls-files", "-co", "--exclude-standard", "-z"], cwd=REPO_ROOT, check=True,
capture_output=True).stdout.decode().split("\0")
return sorted(f for f in out if f and not f.startswith(NO_CODE) and (REPO_ROOT / f).is_file())
def run_step(name, argv, repo: Path, logs: Path, audit: Path) -> dict:
env = {k: v for k, v in os.environ.items() if not k.startswith("ML_POROSITY_")}
env |= {"CUDA_VISIBLE_DEVICES": "", "OMP_NUM_THREADS": "2", "MKL_NUM_THREADS": "2", "OPENBLAS_NUM_THREADS": "2",
"MPLBACKEND": "Agg", "PYTHONPATH": f"{audit}{os.pathsep}{repo}", "PYTHONDONTWRITEBYTECODE": "1",
"REPRO_AUDIT_LOG": str(logs / f"{name}.opens"), "REPRO_ORIGINAL_ROOT": str(REPO_ROOT)}
t0 = time.time()
with open(logs / f"{name}.log", "w") as log:
rc = subprocess.run([sys.executable, *argv], cwd=repo, env=env, stdout=log, stderr=subprocess.STDOUT).returncode
return {"rc": rc, "seconds": round(time.time() - t0, 1)}
def audit_summary(opens: Path, repo: Path, work: Path) -> dict:
"""Files under the clean room's outputs/ and data/ that a step read or wrote, and reads of the original repository
(anything under REPO_ROOT except the clean room itself and the shared interpreter REPO_ROOT/.venv)."""
rd, wr, leak = set(), set(), set()
allowed = (str(work) + os.sep, str(REPO_ROOT / ".venv") + os.sep)
if opens.exists():
for line in opens.read_text().splitlines():
mode, p = line[:1], line[2:]
if p.startswith(str(REPO_ROOT) + os.sep) and not p.startswith(allowed):
leak.add(p)
elif p.startswith(str(repo / "outputs") + os.sep) or p.startswith(str(repo / "data") + os.sep):
(wr if mode == "W" else rd).add(Path(p).relative_to(repo).as_posix())
return {"read": sorted(rd - wr), "written": sorted(wr), "original_repo_reads": sorted(leak)}
def verify(a) -> None:
man = json.loads(MANIFEST.read_text(encoding="utf-8"))
out = Path(a.out)
work = Path(a.work) if a.work else out / "work"
if work.exists():
shutil.rmtree(work)
repo, logs, audit, tmp = work / "repo", work / "logs", work / "audit", work / "raster"
for d in (repo, logs, audit, tmp):
d.mkdir(parents=True)
(audit / "sitecustomize.py").write_text(SITECUSTOMIZE)
t0 = time.time()
files = code_files()
for f in files:
(repo / f).parent.mkdir(parents=True, exist_ok=True)
shutil.copy2(REPO_ROOT / f, repo / f)
figs = sorted(f.name for f in (repo / "paper" / "figures").glob("*.pdf"))
for f in figs: # regenerated by the figure steps, never copied
(repo / "paper" / "figures" / f).unlink()
for rel in (r for rels in REPO_OUTPUTS.values() for r in rels):
(repo / rel).unlink()
for arc, info in man["archives"].items():
if sha256(out / info["file"]) != info["sha256"]:
raise SystemExit(f"archive {info['file']} does not match the manifest")
with tarfile.open(out / info["file"], "r:gz") as tar:
tar.extractall(repo, filter="data")
(repo / "outputs" / "figures").mkdir(parents=True, exist_ok=True) # quick-look PNGs (06, 13) are not packaged
pre = check_tree(repo, man)
print(f"clean room {repo}: {len(files)} code files, {len(pre['ok'])}/{len(man['files'])} package files "
f"({time.time() - t0:.0f} s)", flush=True)
if pre["missing"] or pre["differs"]:
raise SystemExit("extracted package does not match the manifest")
probe = subprocess.run([sys.executable, "-c", "import ml_porosity, ml_porosity.paths as p; print(ml_porosity.__file__, p.outputs_dir())"],
cwd=repo, env={**os.environ, "PYTHONPATH": str(repo)}, capture_output=True, text=True).stdout.split()
if not probe or not probe[0].startswith(str(repo)):
raise SystemExit(f"ml_porosity resolves outside the clean room: {probe}")
by_path = {r["path"]: r for r in man["files"]}
report = {"git_head": subprocess.run(["git", "rev-parse", "HEAD"], cwd=REPO_ROOT, capture_output=True, text=True).stdout.strip(),
"git_dirty": bool(subprocess.run(["git", "status", "--porcelain", "--untracked-files=no"], cwd=REPO_ROOT,
capture_output=True, text=True).stdout.strip()),
"python": sys.version.split()[0], "started_utc": datetime.now(timezone.utc).isoformat(timespec="seconds"),
"code_files": len(files), "package_files": len(man["files"]), "steps": []}
steps = [s for s in STEPS if not a.only or s[0] in a.only]
for name, argv, kind in steps:
before = set(p.relative_to(repo).as_posix() for p in (repo / "outputs").rglob("*") if p.is_file())
t_step = time.time()
r = run_step(name, argv, repo, logs, audit)
au = audit_summary(logs / f"{name}.opens", repo, work)
cmp_ = []
for rel in au["written"]:
f = repo / rel
if rel.startswith("outputs/") and f.is_file():
if rel in by_path:
cmp_.append({"path": rel, **compare_file(f, REPO_ROOT / rel, repo)})
else:
cmp_.append({"path": rel, "status": "new" if rel not in before else "not in package"})
for rel in REPO_OUTPUTS.get(name, []):
cmp_.append({"path": rel, **compare_file(repo / rel, REPO_ROOT / rel, repo)})
if kind == "figures":
for f in sorted((repo / "paper" / "figures").glob("*.pdf")):
if f.stat().st_mtime >= t_step:
cmp_.append({"path": f"paper/figures/{f.name}", **compare_pdf(f, REPO_ROOT / "paper" / "figures" / f.name, tmp)})
if kind == "stdout":
env = {**os.environ, "CUDA_VISIBLE_DEVICES": "", "OMP_NUM_THREADS": "2", "MKL_NUM_THREADS": "2",
"OPENBLAS_NUM_THREADS": "2"}
ref = subprocess.run([sys.executable, *argv], cwd=REPO_ROOT, env=env, capture_output=True, text=True).stdout
new = (logs / f"{name}.log").read_text()
same = new.strip() == ref.strip()
nd = sum(1 for l in difflib.unified_diff(ref.splitlines(), new.splitlines(), lineterm="", n=0)
if l[:1] in "+-" and not l.startswith(("+++", "---")))
cmp_.append({"path": "stdout (vs. the same command on the original outputs)",
"status": "identical" if same else "differs", "detail": "" if same else f"{nd} changed lines"})
rec = {"name": name, "command": "python " + " ".join(argv), "kind": kind, **r,
"n_read_package": sum(1 for p in au["read"] if p in by_path),
"read_outside_package": [p for p in au["read"] if p not in by_path and not p.startswith("data/")][:20],
"read_data": sorted({"/".join(p.split("/")[:3]) for p in au["read"] if p.startswith("data/")}),
"original_repo_reads": au["original_repo_reads"][:20], "compared": cmp_}
if r["rc"]:
rec["log_tail"] = (logs / f"{name}.log").read_text(errors="replace").splitlines()[-15:]
n = {s: sum(c["status"] == s for c in cmp_) for s in ("identical", "equal", "differs", "missing", "new", "not in package")}
print(f"[{name}] rc={r['rc']} {r['seconds']:.0f} s; rewritten: {n}; outside reads: "
f"{len(rec['read_outside_package'])}; original-repo reads: {len(rec['original_repo_reads'])}", flush=True)
report["steps"].append(rec)
(work / "verify.json").write_text(json.dumps(report, indent=1))
if not a.only:
report["figures_not_regenerated"] = [f for f in figs if not (repo / "paper" / "figures" / f).exists()]
report["finished_utc"] = datetime.now(timezone.utc).isoformat(timespec="seconds")
(work / "verify.json").write_text(json.dumps(report, indent=1))
write_report(report, work, DOC / "verify_report.md" if not a.only else work / "verify_report.md")
if not a.keep and not a.only:
shutil.rmtree(work)
def write_report(rep: dict, work: Path, dest: Path) -> None:
L = ["# Clean-room verification of the reproduction package", "",
f"Written by `scripts/39_repro_package.py verify` ({rep['started_utc']} → {rep['finished_utc']}). Code: "
f"{rep['code_files']} files of the working tree at {rep['git_head'][:10]}"
f"{' with uncommitted changes' if rep['git_dirty'] else ''}; package: {rep['package_files']} files from the "
"archives listed in `repro/MANIFEST.json`; Python " + rep["python"] + ", CPU only. No SEG-Y, Volve or "
"Teapot raw data in the clean room; the F3 well files tracked in git are present.", "",
"Status of a rewritten file: identical = same bytes as the original; equal = same values (csv/json/npz "
"within 1e-9 relative, or bytes equal once the clean-room path is replaced by the original one; figures with "
"< 0.01% differing pixels at 110 dpi); differs = see detail; missing = expected but not rewritten; new = "
"written by the step but not part of the package. Reads are those of files under outputs/ (package) and "
"data/ (tracked F3 well files); a read of the original repository would mean the clean room leaked.", "",
"| step | command | exit | s | identical | equal | differs | missing | new | reads outside package | reads of original repo |",
"|---|---|---|---|---|---|---|---|---|---|---|"]
keys = ("identical", "equal", "differs", "missing")
for s in rep["steps"]:
c = s["compared"]
n = {k: sum(x["status"] == k for x in c) for k in keys}
n["new"] = sum(x["status"] in ("new", "not in package") for x in c)
L.append(f"| {s['name']} | `{s['command']}` | {s['rc']} | {s['seconds']:.0f} | "
+ " | ".join(str(n[k]) for k in (*keys, "new"))
+ f" | {len(s['read_outside_package'])} | {len(s['original_repo_reads'])} |")
if "figures_not_regenerated" in rep:
L += ["", "Paper figures deleted from the clean room and not regenerated: "
+ (", ".join(rep["figures_not_regenerated"]) or "none") + "."]
L += ["", "## Details", ""]
for s in rep["steps"]:
L.append(f"### {s['name']}")
L.append(f"- package files read: {s['n_read_package']}"
+ (f"; tracked data read: {', '.join(s['read_data'])}" if s["read_data"] else ""))
for p in s["read_outside_package"]:
L.append(f"- read outside the package: `{p}`")
for p in s["original_repo_reads"]:
L.append(f"- read of the original repository: `{p}`")
for k in ("differs", "missing", "new", "not in package", "equal"):
xs = [x for x in s["compared"] if x["status"] == k]
for x in xs[:25]:
L.append(f"- {k}: `{x['path']}`" + (f" ({x['detail']})" if x.get("detail") else ""))
if len(xs) > 25:
L.append(f"- … {len(xs) - 25} more {k}")
L.append(f"- identical: {sum(x['status'] == 'identical' for x in s['compared'])} file(s)")
if s.get("log_tail"):
L += ["- log tail:", "", "```", *s["log_tail"], "```"]
L.append("")
dest.write_text("\n".join(L) + "\n", encoding="utf-8")
print(f"wrote {dest}")
# ---------------------------------------------------------------- code snapshot
def code(a) -> None:
if subprocess.run(["git", "diff", "--quiet", a.rev, "--"], cwd=REPO_ROOT).returncode:
raise SystemExit(f"tracked files differ from {a.rev}: commit first, then archive that commit")
rev = subprocess.run(["git", "rev-parse", "--short=10", a.rev], cwd=REPO_ROOT, check=True, capture_output=True,
text=True).stdout.strip()
out = Path(a.out) / f"ML-Porosity_code_{rev}.tar.gz"
out.parent.mkdir(parents=True, exist_ok=True)
with open(out, "wb") as f:
subprocess.run(["git", "archive", "--format=tar.gz", f"--prefix=ML-Porosity-{rev}/", a.rev], cwd=REPO_ROOT,
check=True, stdout=f)
print(f"wrote {out} ({out.stat().st_size / 1e6:.1f} MB, sha256 {sha256(out)})")
def main() -> None:
ap = argparse.ArgumentParser(description=__doc__.split("\n")[0])
sub = ap.add_subparsers(dest="cmd", required=True)
b = sub.add_parser("build")
b.add_argument("--dry-run", action="store_true")
c = sub.add_parser("check")
c.add_argument("--root", required=True)
v = sub.add_parser("verify")
v.add_argument("--work", default=None)
v.add_argument("--only", nargs="+", default=None, choices=[s[0] for s in STEPS])
v.add_argument("--keep", action="store_true")
k = sub.add_parser("code")
k.add_argument("--rev", required=True)
for x in (b, v, k):
x.add_argument("--out", default=str(outputs_dir() / "repro"))
a = ap.parse_args()
{"build": build, "check": check, "verify": verify, "code": code}[a.cmd](a)
if __name__ == "__main__":
main()