Olfactory EEG Signal Classification Network
- The paper introduces OESCN, a deep learning framework that classifies olfactory EEG signals using adaptive frequency band extraction and subject-specific attention.
- It employs a four-stage pipeline—PSD estimation, multi-scale band generation, attention mechanism, and a spatio-spectral CNN—to process and classify EEG data.
- Benchmarking shows OESCN achieves 97.1% accuracy, outperforming EEGNet by 13.3% and reducing inter-subject variability significantly.
The Olfactory EEG Signal Classification Network (OESCN) is a deep learning framework specifically designed for classifying electroencephalogram (EEG) signals elicited by olfactory stimuli. The architecture emphasizes adaptive frequency band feature extraction and subject-specific spectral attention, coupled with a compact spatio-spectral convolutional neural network (CNN), achieving robust and high-accuracy classification across individuals for 13-class odor recognition tasks (Sun et al., 2022).
1. Architectural Overview
OESCN is constructed as a four-stage pipeline optimized for extracting discriminative representations from olfactory-induced EEG. The stages are:
- Pre-processing & PSD Estimation: Raw EEG data (C channels, T time samples) are processed via Welch’s periodogram per channel, producing a power spectral density (PSD) representation , where denotes frequency bins over 0.5–70 Hz.
- Frequency Band Generator: A sliding-window mechanism extracts candidate frequency sub-bands over the PSD, aggregating multi-scale bandwise features into .
- Frequency Band Attention Mechanism: Subject-specific attention is imposed on bandwise features: a multi-head self-attention incorporates a global and several local heads, followed by head fusion and a skip connection, yielding a re-weighted spatio-spectral map .
- Spatio-Spectral CNN Classifier: serves as a single-channel 2D “image,” processed via parallel convolutions of varying kernel sizes, pooled, and passed through fully-connected (FC) layers to output a 13-way softmax for odor identification.
The data-flow is: .
2. Frequency Band Generation
The frequency band generator performs an exhaustive, multi-scale sweep over the PSD for each channel:
- For window lengths Hz, with Hz step, the number of bands per :
- For each slice , average spectral power over :
- Concatenate all to form , .
- Band-combination tensor is obtained by stacking across channels.
This process enables high-resolution, adaptive capturing of both narrow and broad frequency features, essential for encoding the olfactory event-related EEG.
3. Frequency Band Attention Mechanism
This module adaptively emphasizes subject-relevant bands through multi-head self-attention:
- Global Head:
- Linear transformations:
where . - Scaled dot-product attention:
Local Heads (for each ): Apply attention as above to each .
Head Fusion:
- Concatenate outputs: .
- Max-pooling and average-pooling:
- Fuse via convolution:
- Add skip connection:
The attention mechanism is explicitly trained for each subject’s dataset split, ensuring adaptation to inter-subject spectral variability.
4. Spatio-Spectral CNN Classifier
The CNN receives interpreted as a single-channel image of size :
Layer 0: Reshape to .
Layer 1: Parallel 2D convolutions:
- , , and kernels ( filters each), ELU activations, concatenated → .
- Layer 2: Average-pooling across spatial dimensions.
- Layer 3: conv with filters (ELU), average-pooling.
- Layer 4: Flatten, FC (128 units, ELU, BN, Dropout 0.25), FC (64 units, ELU, BN, Dropout 0.25), FC (13 units, softmax).
Typical hyperparameters: , , stride=1, padding="same". This structure exploits electrode (spatial) and frequency-band (spectral) topology.
5. Training and Evaluation Protocol
- Dataset: 11 healthy subjects, 13 odors, 35 trials each, yielding 5,005 total trials. EEGs are sampled at 1 kHz over 32 channels (30 analyzed), 10 seconds per trial.
- Pre-processing: PSD extracted via Welch’s method (Hamming window, 200 samples, overlap 8).
- Cross-validation: 10-fold, per subject.
- Optimization: Cross-entropy loss, Adam (), 500 epochs, batch size 39.
Performance Benchmarking:
OESCN was benchmarked against EEGNet and AFBD-SVM; results are summarized below:
| Method | Average Accuracy (%) | Inter-subject Std |
|---|---|---|
| EEGNet | 83.8 | 12.3 |
| AFBD-SVM | 87.3 | 10.2 |
| OESCN | 97.1 | 3.7 |
OESCN delivers a 13.3% gain over EEGNet and substantially reduces inter-subject variability.
6. Ablation Analysis
Two OESCN variants were constructed to assess contribution of each module:
- OESCN_a1: removes the attention mechanism, passing directly to the CNN.
- OESCN_a2: removes both band generator and attention, using fixed uniform sub-bands plus CNN.
| Variant | Avg Acc (%) | Inter-subj Std |
|---|---|---|
| OESCN_a2 | 94.3 | 5.3 |
| OESCN_a1 | 95.9 | 4.5 |
| OESCN | 97.1 | 3.7 |
Removing attention reduces accuracy by ≈1.2%. Eliminating both generator and attention further reduces accuracy by ≈1.6%. This demonstrates that both exhaustive band extraction and subject-specific attention are critical for top performance and robustness.
7. Algorithmic Workflow
A single training epoch for one subject proceeds as:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
for each minibatch {X, y}: # 1. Compute PSD F = Welch_PSD(X) # shape (batch, C, P) # 2. Band generator S = [] for i in 1..5: Li = {1,5,10,15,20}[i] slide_i = sliding_windows(F, length=Li, step=1) D_i = mean_over_window(slide_i) # shape (batch, C, B_i) S.append(D_i) S = concat_along_band_dim(S) # shape (batch, C, K) # 3. Attention H_glo = SelfAttention(S) # global head H_loc = concat(SelfAttention(splits of S)) # local heads M = Conv1x1(concat(maxpool,[H_glo,H_loc], avgpool,[H_glo,H_loc])) M_prime = M + S # 4. CNN Classifier logits = CNN(M_prime) # shape (batch, 13) loss = CrossEntropy(logits, y) backpropagate & update params |
The design leverages a comprehensive multiscale frequency extraction strategy and lightweight subject-specific attention. This hybrid architecture yields state-of-the-art olfactory EEG classification accuracy and significantly enhanced inter-subject robustness (Sun et al., 2022).