Skip to content

Map recipe pre-checks to preprocess - #2337

Merged
neuromechanist merged 2 commits into
feature/issue-2324-epic-pipeline-progressfrom
feature/issue-2324-precheck-maps
Nov 23, 2026
Merged

neuromechanist merged 2 commits into
feature/issue-2324-epic-pipeline-progressfrom
feature/issue-2324-precheck-maps

Conversation

@neuromechanist

@neuromechanist neuromechanist commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Three checks run under a later step's id before that step runs: the floor's robust-amplitude measurement under qc (before bad channels and bad windows), and nemar-ica's rank check under ica and location check under iclabel (before ASR). A recording they refuse would be counted as having passed checkpoints that never ran, and that count is published in neuroschema processing. nemar-process (nemarOrg/nemar-process#74, Phase 3) gives them their own step ids, qc_amplitude, ica_eligibility and iclabel_locations, declared as PRE_CHECKS beside STEP_ORDER and counted at preprocess; this PR makes the registry's maps match.

  • shared/compute-recipes.ts: RECIPE_PRE_CHECKS; qc_amplitude in the floor's preprocess (before bad_channels); ica_eligibility and iclabel_locations in nemar-ica's preprocess (after the re-run qc, before asr).
  • shared/contract/compute-progress-vectors.json regenerated (NEMAR_WRITE_PROGRESS_VECTORS=1): only the maps change.
  • test/compute-recipes-process-drift.unit.test.ts: STEP_ORDER is compared with the map without the pre-checks (they are table step ids, not record steps); each pre-check must sit at preprocess; when the nemar-process checkout declares PRE_CHECKS, they must equal the map's. It passes against nemar-process dev today (no PRE_CHECKS yet) and against the Phase 3 branch.
  • test/compute-recipes.unit.test.ts: the step orders and a pre-check test.

The recipe versions stay 1.0.0-b1: no image has been published, and the record's processing steps are unchanged (the pre-checks are not record steps). After this merges, nemar-process #74 re-pins its progress and runner pins to the new epic commit.

Part of epic #2324

Test plan

  • bun test on compute-recipes.unit, compute-checkpoints.unit (vectors equal the code), compute-progress-contract.unit, compute-recipes-process-drift.unit (required, against the nemar-process Phase 3 tree and against nemar-process origin/dev): 163 pass
  • Backend compute-progress-reconcile, compute-runner-progress, compute-progress-route, compute-pipeline-grid: 77 pass
  • Mutation: dropping qc_amplitude from the floor map fails the drift test
  • bun run typecheck, bun run lint, biome on the touched files
  • Not run: the full bun test (epic to dev gate)

Review round 1

  • I1 (vectors) -> ica_mixed: the d.set row's step is now ica_eligibility, and a new h.set row fails step_failed at iclabel_locations; floor_mixed: a new i.set row fails step_failed at qc_amplitude. Regenerated with NEMAR_WRITE_PROGRESS_VECTORS=1. nemar-process Add BIDS CI at upload, push --pr, dataset ci command #74's Python replay passes with the new vectors (scratch archive of Add BIDS CI at upload, push --pr, dataset ci command #74 head: test_progress_rules.py 53 passed on Python 3.9, test_checkpoint_maps.py 7 passed).
  • I2 (drift test) -> a steps.py that declares CHECKPOINTS must declare PRE_CHECKS, and its CHECKPOINTS (parsed by a new checkpointsOf, pinned on literal text) must equal the registry's map step for step. Against nemar-process dev (no CHECKPOINTS yet): 9 pass. Against an archive of Add BIDS CI at upload, push --pr, dataset ci command #74: 9 pass. Mutations on that archive: PRE_CHECKS deleted from nemar_ica fails 1; qc_amplitude moved to quality in the floor fails 1.
  • S1/S2 (stale comments) -> the drift test header and title, and the unit test's comment, now say the map's step lists are STEP_ORDER plus PRE_CHECKS.

Round 1 gates: compute-recipes.unit, compute-checkpoints.unit, compute-progress-contract.unit 155 pass; backend compute-progress-reconcile, compute-runner-progress, compute-progress-route, compute-pipeline-grid 77 pass; typecheck, lint, biome clean. The full bun test was not run (epic to dev gate).

@github-actions

github-actions Bot commented Nov 23, 2026 •

Copy link
Copy Markdown

📦 Package Preview

Your package is ready to test!

bun install -g nemar-cli@PR2337

Version: 0.10.40-PR2337.7c721e1
Commit: 7c721e1


🤖 Updated on each push.

@neuromechanist

Copy link
Copy Markdown
Contributor Author

Review converged: one reviewer (code+tests), round-1 findings fixed in 7c721e1 (pre-check vectors, strict drift test, comments). All checks green.

@neuromechanist
neuromechanist merged commit 1b64536 into feature/issue-2324-epic-pipeline-progress Nov 23, 2026
27 checks passed
@neuromechanist
neuromechanist deleted the feature/issue-2324-precheck-maps branch November 23, 2026 14:46

This branch was previously deployed

1 inactive deployment
npm — 7c721e18 Deployed Nov 23, 2026 by neuromechanist via publish #4804
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant