path-bci

Decoding and BCI engineer

For: ML / neurotech engineers. 18 steps · ~19 h.

Why this order

This path assumes you can already build a classifier and cannot yet tell whether the thing it is classifying is brain activity. It is therefore ordered by what can invalidate a decoding result, from the most physical cause to the most statistical.

Acquisition and artifacts first (L0.3–L0.5). A decoder will happily learn jaw tension, blinks or an electrode drift, and it will report excellent accuracy for doing so. L0.5 is the lesson that lets you recognise what your features are made of; L0.3 is where sampling rate, hardware bandwidth and trigger timing are established, all three of which bound what any online system can do.

Then the two signal-processing lessons that decoders actually depend on (L1.1, L1.5, L1.6): aliasing and usable bandwidth, filter design with its causal/zero-phase distinction — which becomes a latency budget in L7.3 — and the line noise that sits inside the band most motor-imagery features are computed over.

Then the preprocessing steps that change the feature space (L2.2, L2.4–L2.7). Bad channels matter more for spatial filters than for anything else, because a spatial filter is a weighted sum of channels and one bad channel enters every component. L2.7 is placed last of these because ASR and its relatives are the cleaning methods that survive real-time and low-channel constraints.

Then the feature representation (L4.2–L4.4): time-frequency estimation and ERD/ERS, which is where band power — the input to most motor-imagery pipelines — is defined and baseline-normalised.

Then the spatial filters themselves (L5.7), including the distinction between filters and patterns that decides whether a component can be interpreted at all.

Then evaluation before application (L6.5 before L7.1). Cross-validation on EEG leaks across folds in several ways that are specific to this data — trials from the same block, the same session, the same subject — and a pipeline evaluated wrongly is worse than no pipeline. L7.1 and L7.3 then apply all of it, offline and online.

Levels 3 and the rest of Level 6 are skipped: an ERP-based BCI can be built from the P300 material in L7.1 without the full ERP measurement and statistics chain.

Paths do not add content; they filter and order the ladder (§7). Lesson pages keep their own prerequisite links.

Lessons (18; about 18 h 30 min of lesson time)

  1. L0.3 Amplifiers, sampling and recording · 45 min
  2. L0.4 Reading raw traces · 60 min
  3. L0.5 The artifact atlas · 75 min
  4. L1.1 Sampling, Nyquist and aliasing · 40 min
  5. L1.5 Filters: FIR, IIR, and what they do to your data · 75 min
  6. L1.6 Line noise · 40 min
  7. L2.2 Channel locations and bad channels · 60 min
  8. L2.4 Filtering in practice · 45 min
  9. L2.5 Artifact rejection strategies · 50 min
  10. L2.6 EOG regression and ICA · 90 min
  11. L2.7 ASR, SSP and alternatives · 45 min
  12. L4.2 STFT and Morlet wavelets · 75 min
  13. L4.3 Multitaper and filter-Hilbert · 50 min
  14. L4.4 Baseline normalization and ERD/ERS · 60 min
  15. L5.7 Spatial filters for decoding · 60 min
  16. L6.5 Decoding as inference · 60 min
  17. L7.1 Decoding and BCI · 90 min
  18. L7.3 Real-time processing and neurofeedback · 90 min

Skipped prerequisites (optional reading)

Each of these is a prerequisite of a lesson this path includes. They are optional here, not removed — the lesson pages keep their prerequisite links.

  • L0.2 Electrodes, montages and the 10-20 system — a prerequisite of L0.4. Read it before choosing a channel subset or comparing montages across datasets; a spatial filter is only as meaningful as the positions behind it.
  • L1.2 Time and frequency domains — a prerequisite of L1.3 and the Fourier grounding for every band-power feature.
  • L1.3 Power spectral density — a prerequisite of L1.4 and L1.6. Band power is an integral over a spectrum, and this is where the estimator and its variance are defined.
  • L1.4 Windowing, leakage and zero-padding — a prerequisite of L4.2; it sets the window length against resolution trade-off that a real-time buffer makes concrete.
  • L2.1 Loading data and BIDS — a prerequisite of L2.2. Read it when you start running over a cohort rather than a file.
  • L2.3 Re-referencing — a prerequisite of L2.4. Spatial filters operate on referenced data, and a change of reference changes the feature space, so this matters more here than the omission suggests.
  • L4.1 Why time-frequency — a prerequisite of L4.2; the evoked-versus-induced distinction is what tells you whether your features should come from an average or from single trials.

Lessons in order

  1. L0.3 · Amplifiers, sampling and recording ~45 min
  2. L0.4 · Reading raw traces ~60 min
  3. L0.5 · The artifact atlas ~75 min
  4. L1.1 · Sampling, Nyquist and aliasing ~40 min
  5. L1.5 · Filters: FIR, IIR, and what they do to your data ~75 min
  6. L1.6 · Line noise ~40 min
  7. L2.2 · Channel locations and bad channels ~60 min
  8. L2.4 · Filtering in practice ~45 min
  9. L2.5 · Artifact rejection strategies ~50 min
  10. L2.6 · EOG regression and ICA ~90 min
  11. L2.7 · ASR, SSP and alternatives ~45 min
  12. L4.2 · STFT and Morlet wavelets ~75 min
  13. L4.3 · Multitaper and filter-Hilbert ~50 min
  14. L4.4 · Baseline normalization and ERD/ERS ~60 min
  15. L5.7 · Spatial filters for decoding ~60 min
  16. L6.5 · Decoding as inference ~60 min
  17. L7.1 · Decoding and BCI ~90 min
  18. L7.3 · Real-time processing and neurofeedback ~90 min