Skip to content

Phase 6: Advanced display modes, linked windows, component views, and property flows #100

Closed

Description

@suraj-ranganath

🤖 Phase 6 for the EEGBrowser epic. Target branch: feature/eegbrowser-completion.

Dependency

Start after Phase 4 merges. This can run in parallel with Phase 5.

Goal

Implement advanced browser surfaces that are needed for full parity beyond the basic channel-scrolling and visual-rejection workflows.

Implementation scope

  • data2 overlay and before/after comparisons such as pop_subcomp plot confirmation.
  • Component activity scrolling and ICA activation display.
  • Linked/child windows for synchronized scrolling.
  • noui / publication-style view where compatible.
  • Frequency/spectral display mode with freqs and freqlimits.
  • eeg_multieegplot.
  • Browser-backed portions of pop_viewprops and component/property workflows that currently omit scrolling activity.

Acceptance criteria

  • Component and channel browser modes match EEGLAB labels, limits, and scaling.
  • Linked windows scroll together.
  • data2 overlays are visually distinct and tested.
  • pop_subcomp(plotag=True) no longer raises browser-not-implemented.
  • eeg_multieegplot supports old/new rejection colors for epoched data.
  • No runtime code depends on src/eegprep/eeglab.

Tests and evidence

  • Unit and GUI tests for component mode, data2, linked windows, spectral mode, noui, and eeg_multieegplot.
  • Sample-data tests with ICA/component-capable fixtures where available.
  • Visual parity screenshots attached to the phase PR as GitHub user attachments.
  • uv run --no-sync ruff check .
  • uv run --no-sync ruff format --check .
  • uv run --no-sync ty check
  • Focused pytest for changed tests.

/goal prompt

/goal Implement advanced EEGBrowser display modes from this issue: component activity scrolling, data2 overlays, linked windows, noui-style display, frequency display, eeg_multieegplot, and property-flow browser integration. Verify against EEGLAB source, visual parity screenshots, sample_data, GUI/console user flows, ruff/format/ty, and focused pytest.

Required references for every phase

  • AGENTS.md
  • .agents/skills/eegprep-feature-development/SKILL.md
  • .agents/skills/eeglab-gui-visual-parity/SKILL.md for GUI features
  • .agents/skills/gui-agent-flow-qa/SKILL.md for end-user flow QA
  • EEGLAB reference under src/eegprep/eeglab, used only as development/parity input.

Core EEGLAB references

  • src/eegprep/eeglab/functions/sigprocfunc/eegplot.m
  • src/eegprep/eeglab/functions/sigprocfunc/eegplotlegacy.m
  • src/eegprep/eeglab/functions/sigprocfunc/eegplot2event.m
  • src/eegprep/eeglab/functions/sigprocfunc/eegplot2trial.m
  • src/eegprep/eeglab/functions/sigprocfunc/trial2eegplot.m
  • src/eegprep/eeglab/functions/popfunc/pop_eegplot.m
  • src/eegprep/eeglab/functions/popfunc/eeg_rejmacro.m
  • src/eegprep/eeglab/functions/popfunc/eeg_multieegplot.m

Activity

  1. added
    phase
    on May 31, 2026
  2. claude commented on May 31, 2026

    @claude
    Contributor

    🤖 Plan:

    Research

    Phase 6 is a multi-module epic feature, not a self-contained bug fix. Per epic #94's merge order (1 → 2+3 → 4 → 5+6 → 7), this issue's own "Dependency" line requires Phase 4 (#98) to merge first. Current state: Phases 1–5 (#95, #96, #97, #98, #99) are all still OPEN, and origin/feature/eegbrowser-completion is at the same commit as origin/develop (0 commits ahead) — no browser foundation code exists yet to build on.

    Relevant code (current EEGPrep state — all browser surfaces are still stubs/exclusions):

    • src/eegprep/functions/guifunc/menu_placeholders.py#L39 — pop_eegplot flagged excluded_reason="eegbrowser"
    • src/eegprep/functions/guifunc/eeglab_menu.py#L161,L231,L254 — pop_eegplot:data, :channels, :components menu actions wired but unimplemented
    • src/eegprep/functions/popfunc/pop_subcomp.py#L39-L43 — raises NotImplementedError when plotag truthy (the exact case Phase 6 must fix)
    • src/eegprep/plugins/ICLabel/pop_viewprops.py#L99-L100 — explicitly omits scrolling activity pending EEGBrowser
    • src/eegprep/functions/popfunc/pop_rejmenu.py#L264, pop_autorej.py#L68, pop_select.py#L656 — eegplot buttons disabled / TODO
    • No eegplot.py, pop_eegplot.py, or eeg_multieegplot.py in src/eegprep/functions/sigprocfunc/ or popfunc/ yet

    No duplicate PR exists (gh pr list --search \"EEGBrowser Phase 6\" → empty).

    Proposed approach (for human review — not implementing)

    Do not start Phase 6 yet. It has no foundation to call: Phase 1 defines the eegplot/EEGBrowser data model + rendering API that every Phase 6 surface (component scroll, data2 overlay, linked windows, spectral mode, noui, eeg_multieegplot) must extend. Implementing Phase 6 first would mean inventing the Phase 1 API in this PR, which collides with #95 and guarantees rework on merge.

    When Phase 4 (#98) merges into feature/eegbrowser-completion, the scope here breaks into roughly seven independent slices, each landable as a focused commit on agent/YYYYMMDD-fix-100:

    1. Component activity mode — extend Phase 1's eegplot(data, …) to accept icaact/icawinv+icasphere+icaweights+icachansind, gated by an ica='on' option matching eegplot.m. Wire eeglab_menu.py#L254 (pop_eegplot:components).
    2. data2 overlay — second-trace rendering with distinct color/alpha, parity with EEGLAB data2 arg in eegplot.m. Drives pop_subcomp(plotag=True) confirmation; replace the NotImplementedError in pop_subcomp.py#L39.
    3. Linked/child windows — shared BrowserState (from Phase 1) cross-window, with children= option semantics from eegplot.m.
    4. noui / publication view — render path that hides toolbar/menus when 'noui','on', suitable for figure export.
    5. Frequency/spectral mode — freqs/freqlimits options; precompute via existing spectopo/welch and reuse Phase 1 scroll plumbing.
    6. eeg_multieegplot — port eeg_multieegplot.m with old/new rejection-color stacking for epoched data; new module under functions/popfunc/.
    7. pop_viewprops browser integration — restore scrolling activity at ICLabel/pop_viewprops.py#L99-L100; remove the exclusion strings.

    Each slice needs: unit test on a synthetic EEG dict, visual parity capture under tools/visual_parity/cases.json against the matching EEGLAB MATLAB figure, EEGPrep-owned help md under src/eegprep/resources/help/, and no runtime read from src/eegprep/eeglab/.

    Open questions for a human before any code is written:

    • Should pop_viewprops browser restoration land here or in Phase 5 (Phase 5: Browser integration for rejection and cleaning workflows #99)? Phase 5's title ("rejection and cleaning") could plausibly own the property-flow integration; current Phase 6 scope claims it.
    • eeg_multieegplot parity target — full MATLAB API (oldcolor,newcolor,command,spacing,...) or just GUI-visible behavior?
    • Acceptance says "child windows scroll together" — does linked-scroll need to survive Qt event-loop reentrancy across EEGPrepSession mutations, or only same-process same-session?

    Recommended next step: wait for #95 (Phase 1) and #98 (Phase 4) to merge into feature/eegbrowser-completion, then re-trigger this issue. Re-running now would either block on stubs or invent Phase 1's contract and collide with that PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

phase

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions