feat(evaluate): an OSSE benchmark recipe with a no-DA baseline and sweep axes

Aperta
#168 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
35/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
python

Direzione di ricerca

Read packages/pipekit-evaluate/src/pipekit_evaluate/benchmark/protocols.py, benchmark/run.py, and benchmark/reference.py first, then inspect the existing cycle integration and the cited OSSE notebooks. The issue names the target benchmark/osse.py and calls for osse_task, FreeRun, osse_sweep, timing, and a docs recipe. Done means the listed behavior, tests, docs, docstrings, lint, and type checks are complete.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

area:code priority:p2 type:feature

Problem / Request

Add the first concrete recipe to pipekit-evaluate's benchmark ladder: an OSSE that goes from a nature run through observations and a cycle to a score against truth, with a no-DA free run as the baseline every method must beat.

User Story

As a DA method author, I want one call that runs a method through a standard OSSE and a sweep of its difficulty, so that my result compares directly with a baseline and with other methods.

Motivation

pipekit-evaluate has the cube, the protocols and the reference rule, but no recipe that fills them.
The OSSE protocol is published: Solvik, Penny and Hoyer (2024), with notebooks under examples/da_cycler/Solvik_Penny_Hoyer_2024-Backprop4DVar/ in https://github.com/StevePny/DataAssimBench-Examples.
Its reported sweep uses system dimensions {6, 20, 36, 72, 144, 256} on Lorenz-96, observed counts from 6 to 36, and observation error σ from 0.1 to 2.0.
It reports analysis RMSE and wall-clock time together.

Proposed API

# Shapes: N_t times; D_x state size
# proposed (this issue)
task = osse_task(
    "lorenz96-40",
    simulator=forward_model,              # today (pipekit-cycle): ForwardModel
    truth0=x0,                            # (D_x,)
    n_steps=500,
    obs_op=obs_op,                        # today (pipekit-cycle): ObservationOperator
    plan=plan,                            # proposed: ObservationPlan
    noise=noise,                          # today (pipekit-cycle): ObservationNoise
)                                         # datasets(): {"truth", "obs", "record"}

baseline = FreeRun(simulator=forward_model, x0=x0_perturbed)   # proposed: no assimilation

report = Benchmark(task, estimators=[baseline, method], scorers=[rmse]).run()   # today*

# one Benchmark per point of the sweep
benchmarks = osse_sweep(build_task, dims=(6, 20, 36), obs_counts=(6, 12), obs_sigmas=(0.1, 1.0))

Mathematical Notes

Here x_t is the truth, x̂_t is an estimate, N_t is the number of scored times, and D_x is the state size.
The score is analysis RMSE against truth:

\mathrm{RMSE} = \sqrt{\frac{1}{N_t D_x} \sum_{t=1}^{N_t} \lVert \hat{x}_t - x_t \rVert_2^2}

The baseline starts from the same perturbed initial condition as the method and never uses an observation.
An analysis that does worse than the baseline has made the state worse than having no observations.

References & Existing Code

  • Task, Estimator and Scorer in packages/pipekit-evaluate/src/pipekit_evaluate/benchmark/protocols.py @ 7c446f1.
  • Benchmark.run in benchmark/run.py and ReferenceSource in benchmark/reference.py @ 7c446f1.
  • The cycle extra of pipekit-evaluate already exists for the dependency on pipekit-cycle.

Implementation Steps

  • Add osse_task, FreeRun and osse_sweep in packages/pipekit-evaluate/src/pipekit_evaluate/benchmark/osse.py, behind the cycle extra.
  • Record the wall-clock time per estimator, because the published protocol reports it next to the error.
  • Add a docs example on a small system; don't run the full published sweep in CI.

Definition of Done

  • Code lands at the intended path.
  • Tests pass: make test.
  • Lint + typecheck pass: make lint && make typecheck.
  • Docstrings (Google-style) on all public symbols.

Testing

  • On a linear toy system with a Kalman analysis, the method's RMSE is below FreeRun's.
  • A method that ignores every observation scores equal to FreeRun, to 1e-12.
  • Equal seeds give equal reports, apart from the timing fields.
  • osse_sweep yields one Benchmark per point of the Cartesian product of its axes.

Documentation

  • A recipe page in pipekit-evaluate's docs.

Relationships

  • Parent (theme epic): #149
  • Blocked by: #166
  • Related: #44, jejjohnson/vardax#53
Lingua principale
Python
Stelle
0
Fork
0
Merge medio
3h 50m
PR unite (30g)
143

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di jejjohnson/pipekit

Tutte le issue di jejjohnson/pipekit

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.