Repository navigation
NEMAR: a clearer notebook welcome and a curated first plot - #577
Merged
neuromechanist merged 3 commits intoOct 1, 2026
Merged
Conversation
Retitle the starter as a Python playground, state that code, edits and results stay on the reader's machine while data streams in, name what eegprep-lean does and does not do yet, and note that MNE does not install in this Pyodide 0.29.5 runtime. Tested: starter, notebook-lock and notebook-site tests pass.
Set the PSD y-limits and the ERP image color range before drawing, sort ERP image rows (by response time, or by response amplitude) and then smooth them, say how rows are ordered and offer one other sort, and describe the structure a plot shows rather than calling the recording noise. The first figure is the one an expert would expect. Tested: NEMAR prompt, config and runtime tests pass; the plots themselves are not yet checked against a live recording.
Notebook: say the latest MNE does not install (an older release does), use the package's own name for eegprep-lean, define ERP and ICLabel where first used and once only, and restore the setup cell's Ready instruction. Prompt: log y-axis and a top limit that keeps named peaks, response_time read from columns_summary in seconds with paired-copy length assert, the first response within the epoch, 'order' instead of 'sort' to avoid the pinned events rule, an amplitude ordering described as imposed structure, and no blanket ban on the word noise. Tested: 943 Python tests, notebook/test-open.js and frontend/test-data-lane.js pass.
neuromechanist
deleted the
feature/nemar-playground-welcome-and-plot-guidance
branch
October 1, 2026 19:13
10 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Two changes to what a first-time NEMAR reader sees.
starter.ipynb): retitled "Python playground for {dataset}" with a short welcome. It says data streams in while code, edits and results stay on the reader's machine, thateegprep-leanreads recordings and plots signals, that spectra and event-related potential (ERP) images are SciPy, NumPy and matplotlib recipes, that EEGPrep preprocessing and ICLabel are not in the browser yet, that the latest MNE does not install here yet, and that the Zarr copy is lossy.config.yamlsystem prompt, "Spectra, events and ERP images"): the first figure should be the one an expert expects. The PSD y-limits and the ERP image color range are set before drawing. ERP image rows are ordered (reader's choice, else response time, else each epoch's amplitude in a window), then smoothed. The assistant says how rows are ordered, offers one other ordering, and describes what the plot shows rather than calling the recording noise.Checked facts
eegprep-lean0.1.0.dev3 (the vendored wheel, and the latest change topackages/eegprep-leanonsccn/eegprepdevelop) reads and plots only; its README says preprocessing is not implemented. PSD and ERP image are SciPy, NumPy and matplotlib recipes, as in the NEMAR examples. Browser ICLabel is open upstream (Phase 5: Browser ICLabel via ONNX Runtime Web with an await-able entry point sccn/eegprep#378). A help entry point was requested in eegprep-lean: add a help entry point and list lazy names in dir() sccn/eegprep#428.micropip.install("mne")fails: MNE 1.13.2 needs matplotlib 3.9 or newer and Pyodide ships 3.8.4.micropip.install("mne<1.13")installs MNE 1.12.1 and imports (tested with micropip directly, not on the deployed JupyterLite site).Review
Three Sonnet reviews (code, text accuracy, tests) and an earlier Opus consult on placement. Addressed in the last commit: the MNE claim scoped to the latest release, the PSD limit rule (log y-axis, top limit keeps named peaks), the response-time wording (read
response_timefromcolumns_summary, in seconds, paired copy under a length assert), the amplitude-ordering caveat versus the tone rule, "order" instead of "sort" next to the pinned events rule, abbreviations defined once, and the CHANGELOG wording.Left as written, on purpose: "Your code, edits and results never leave your machine" and "streams NEMAR's Zarr data to run your code locally" are the maintainer's wording; the first was verified for code, edits and results (the notebook site makes no call to the OSA API).
Testing
uv run pytest tests/test_assistants tests/test_core/test_config tests/test_scripts/test_build_notebook_site.py: 943 passed, 11 skipped.bun notebook/test-open.js(52) andbun frontend/test-data-lane.js(106) pass.xx099905on the dev deployment after merge: the develop chat reads NEMAR's staging server, which has thexx0999NNfixtures, not production datasets such asnm000132.