Repository navigation
Closed
Labels
phaseEpic implementation phase
Description
🤖 Phase issue for the EEGLAB completion epic.
Goal
Complete parity for signal conditioning, filtering, baseline removal, boundary-aware data transforms, and bundled cleaning workflows.
Target branch and PR flow
- Create the phase branch from
feature/eeglab-completion. - Open the phase PR back into
feature/eeglab-completion. - The phase PR should close this issue.
Parallelization
Can run in parallel with Phases 1, 3, and 4. Coordinate shared helpers for event, urevent, boundary, epoch, and ICA invalidation semantics.
In scope
- Legacy and new FIR filtering workflows and firfilt menu actions.
- Baseline removal and low-level
rmbaseparity. - Continuous and epoched boundary handling.
- Epoch-to-continuous and time-interpolation helpers needed by EEGLAB parity.
- Rerejection-support helpers that do not require EEGBrowser.
- clean_rawdata parity gaps already represented in this repo.
- GUI dialogs, help Markdown, console commands, history strings, and menu dispatch for implemented workflows.
Out of scope
- EEGBrowser/eegplot scrolling viewers.
- External plugins not vendored in this repo.
Acceptance criteria
- Tools filtering/baseline/cleaning actions operate on continuous and epoched EEG like EEGLAB.
- Boundary events, ICA invalidation/reactivation,
urevent,epoch,times, andhistorybehavior match EEGLAB expectations. - Numerical tests include MATLAB parity,
sample_data, small synthetic data, edge sampling rates, boundary events, and invalid parameters. - GUI dialogs match EEGLAB layout and remain responsive from
eegprep-console. - Successful expected workflows do not emit noisy warnings unless EEGLAB-equivalent behavior requires them.
- Required lint/type/test commands pass.
/goal prompt
/goal Complete EEGPrep parity for signal conditioning, filtering, baseline removal, and bundled cleaning workflows. Use EEGLAB source as oracle, preserve standalone runtime behavior, verify with MATLAB parity tests, sample_data integration tests, GUI visual parity where dialogs exist, console/GUI workspace tests, ruff/format/ty, and non-slow pytest. Continue until all category placeholders are either implemented or documented as explicit browser/external exclusions.
Metadata
Metadata
Assignees
Labels
phaseEpic implementation phase
Activity
claude commentedon May 27, 2026
🤖 Plan:
Research
Phase 2 is an EEGLAB-completion epic, not a bug fix. It spans Tools→Filter, Tools→Remove baseline, continuous/epoch boundary semantics, epoch↔continuous helpers, and clean_rawdata parity gaps. Implementing it as one PR would be thousands of LOC across
popfunc/,sigprocfunc/,plugins/firfilt/,plugins/clean_rawdata/,guifunc/,resources/help/, MATLAB parity tests, and console wrappers — out of scope for an automated single-PR fix.Current state vs. scope
plugins/firfilt/menu.pydispatches topop_eegfiltnew,pop_firws,pop_firpm,pop_firma; all four (plus legacypop_eegfilt,pop_iirfilt) are still infunctions/popfunc/_coming_soon.pyPLACEHOLDER_ACTIONS. Onlyfirws/firwsordports exist underplugins/firfilt/. Nopop_*wrappers, no GUI dialogs, no help md.functions/popfunc/pop_rmbase.pyis partially implemented (boundary-aware_normalize_pointrange) butpop_rmbaseis still listed inPLACEHOLDER_ACTIONSand has no help md, no console/GUI wiring audit, no MATLAB parity test confirmed.eeg_findboundaries,eeg_lat2point,eeg_point2lat,eeg_eegrej,pop_epochpresent. Missing per EEGLAB:eeg_regepochs,epoch2continuous,pop_eegrejuser-facing wrapper, and a documented invariant pass forurevent/epoch/times/historyafter boundary rejection.pop_rejcont,pop_eegthresh,pop_jointprob,pop_rejkurt,pop_rejtrend,pop_rejspec,pop_rejepochall inPLACEHOLDER_ACTIONS. (Note: most overlap Phase 3 ICA-rejection — needs an explicit boundary with Phase 3: ICA, component, rejection, ICLabel, and DIPFIT workflows #63.)clean_artifacts,clean_asr,clean_channels,clean_channels_nolocs,clean_drifts,clean_flatlines,clean_windows,pop_clean_rawdataall ported. Gaps are in MATLAB parity coverage on boundary-aware continuous data, edge sample rates, and history string format — not in missing modules.pop_clean_rawdata.md,clean_artifacts.md,pop_epoch.md,pop_resample.md,pop_select.md,pop_reref.md,reref.md,pop_interp.md. Missing for everything else in this phase.Relevant code
eeg_eegrej.py— boundary primitives Phase 2 builds onBranch + duplicate-work preflight
feature/eeglab-completionexists (HEAD93fa421) but has no commits ahead ofdevelop; phase work hasn't started.Proposed Approach (design change — needs human review before any PR)
Break Phase 2 into 5 reviewable PRs against
feature/eeglab-completion. Each is independently testable, fits well under 500 LOC excluding tests/help, and removes the matching entries fromPLACEHOLDER_ACTIONSonly as ports land. Suggested order matches dependency direction:pop_rmbasefinalize. Audit current implementation againsteeglab/functions/popfunc/pop_rmbase.m, confirm boundary-aware behavior on continuous and epoched data, add MATLAB parity test, addresources/help/pop_rmbase.md, wire console+GUI dialog, drop fromPLACEHOLDER_ACTIONS. Depends on nothing.pop_eegfiltnew(default), thenpop_firws,pop_firpm,pop_firma. Use existingplugins/firfilt/firws.py/firwsord.pyfor kernels; share a private_apply_fir.pyhelper for boundary-aware filtfilt across continuous and epoched data. One PR per pop function to keep diffs small. Each PR ships GUI dialog (visual parity vs EEGLAB screenshot), help md, console wrapper test, MATLAB parity test onsample_data, removal fromPLACEHOLDER_ACTIONS. Skippop_eegfiltlegacy andpop_iirfiltunless explicitly requested — EEGLAB defaults topop_eegfiltnew.eeg_regepochsandepoch2continuous, addpop_eegrejwrapper over existingeeg_eegrej. Establish a single internal invariant helper forurevent/event/epoch/times/history/icaactupdates post-boundary that every Phase 2 mutator calls. Parity tests must cover first/last sample, repeated boundaries, and ICA invalidation/reactivation.clean_artifacts,clean_asr,clean_channels,clean_drifts,clean_flatlines,clean_windowson boundary-aware continuous data and edge sampling rates; tighten history strings to match EEGLAB. Help md additions where missing.pop_rejcontandpop_rejepoch(continuous and epoch-level marking that does not need a scrolling viewer). Deferpop_eegthresh/pop_jointprob/pop_rejkurt/pop_rejtrend/pop_rejspecto Phase 3 (Phase 3: ICA, component, rejection, ICLabel, and DIPFIT workflows #63) since they sit on the ICA component-rejection axis and the boundary is ambiguous in this issue.Open questions for the human before implementation
pop_*filter as its own issue rather than chained PRs under Phase 2: Signal conditioning, filtering, baseline, and cleaning #62?pop_eegfilt(legacy) andpop_iirfiltat all? EEGLAB still ships them but defaults topop_eegfiltnew; leaving them as placeholders matches the "out of scope: external plugins not vendored" clause.pop_rejcont+pop_rejepochhere, everything ICA-driven there..agents/skills/eeglab-gui-visual-parity/SKILL.md), or layout-equivalent acceptable?No PR opened. Awaiting direction on (1)-(5) before starting subphase 1.