双分支频谱-时序注意力EEG疲劳检测:SFT-Net频空时四维联合建模

论文信息

项目 内容
标题 A Dual-Branch Spectral–Temporal Attention Fusion Network for EEG-Based Driving Fatigue Detection
期刊 IEEE Journal of Biomedical and Health Informatics
发表 2026年1月12日
链接 https://ieeexplore.ieee.org/iel8/19/11329398/11345326.pdf
核心方法 SFT-Net:双分支频谱+时序注意力融合
输入 4D EEG表示(通道×频段×空间×时间)
数据集 SADT + SEED-VIG

核心创新

  1. 双分支解耦:频谱分支+时序分支独立建模后融合
  2. 4D EEG表示:通道×频段×空间×时间四维联合
  3. 频谱注意力:自适应加权δ/θ/α/β/γ频段
  4. 时序注意力:窗口方差描述子+分组注意力

方法详解

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
import torch
import torch.nn as nn
import numpy as np

class SpectralBranch(nn.Module):
"""频谱分支:自适应频段权重学习"""

def __init__(self, n_channels=17, n_bands=5):
super().__init__()
self.band_attention = nn.Sequential(
nn.Linear(n_bands, n_bands * 2),
nn.ReLU(),
nn.Linear(n_bands * 2, n_bands),
nn.Sigmoid()
)
self.conv = nn.Sequential(
nn.Conv2d(n_channels, 32, (n_bands, 3), stride=1),
nn.BatchNorm2d(32),
nn.ReLU(),
nn.Conv2d(32, 64, (1, 3), stride=2),
nn.BatchNorm2d(64),
nn.ReLU(),
nn.AdaptiveAvgPool2d(1),
nn.Flatten()
)

def forward(self, x):
"""x: [B, C, F, T]"""
B, C, F, T = x.shape
band_weights = self.band_attention(
x.mean(dim=(2, 3)) # [B, F]
)
x = x * band_weights.unsqueeze(1).unsqueeze(3)
return self.conv(x)


class TemporalBranch(nn.Module):
"""时序分支:窗口方差+分组注意力"""

def __init__(self, n_channels=17):
super().__init__()
self.conv = nn.Conv1d(n_channels, 64, 5, stride=2)
self.lstm = nn.LSTM(64, 128, batch_first=True, bidirectional=True)
self.attention = nn.Sequential(
nn.Linear(256, 64),
nn.ReLU(),
nn.Linear(64, 1)
)

def forward(self, x):
"""x: [B, C, T]"""
feat = self.conv(x) # [B, 64, T']
feat = feat.permute(0, 2, 1) # [B, T', 64]
out, _ = self.lstm(feat)
att = torch.softmax(self.attention(out), dim=1)
context = (out * att).sum(dim=1)
return context


class SFTNet(nn.Module):
"""SFT-Net: 双分支频谱-时序注意力融合"""

def __init__(self, n_classes=3):
super().__init__()
self.spectral = SpectralBranch(n_channels=17, n_bands=5)
self.temporal = TemporalBranch(n_channels=17)
self.fusion = nn.Sequential(
nn.Linear(64 + 256, 128),
nn.ReLU(),
nn.Dropout(0.3),
nn.Linear(128, n_classes)
)

def forward(self, eeg_4d, eeg_2d):
"""eeg_4d: [B,C,F,T], eeg_2d: [B,C,T]"""
spec_feat = self.spectral(eeg_4d)
temp_feat = self.temporal(eeg_2d)
fused = torch.cat([spec_feat, temp_feat], dim=-1)
return self.fusion(fused)


# 测试
if __name__ == "__main__":
model = SFTNet(n_classes=3)
eeg_4d = torch.randn(4, 17, 5, 100)
eeg_2d = torch.randn(4, 17, 100)
out = model(eeg_4d, eeg_2d)
print(f"SFT-Net输出: {out.shape}")
print(f"参数: {sum(p.numel() for p in model.parameters()):,}")

实验结果

方法 SADT准确率 SEED-VIG准确率
CNN 85.2% 82.1%
BiLSTM 87.5% 84.3%
SFT-Net 93.8% 91.2%

频段注意力权重

频段 清醒权重 疲劳权重 变化
δ(1-4Hz) 0.10 0.25 +150%
θ(4-8Hz) 0.15 0.28 +87%
α(8-13Hz) 0.25 0.20 -20%
β(13-30Hz) 0.30 0.17 -43%
γ(30-45Hz) 0.20 0.10 -50%

IMS开发启示

与DeltaGateNet对比

维度 DeltaGateNet(#24) SFT-Net 选择
参数 45K 320K DeltaGateNet更轻
输入 时序EEG 4D EEG SFT-Net更丰富
注意力 频谱+时序 SFT-Net更精细
部署 耳道1-4ch 全帽17ch DeltaGateNet更实用

集成方案

层级 模型 输入 角色
边缘 DeltaGateNet 耳道EEG 实时推理2ms
云端 SFT-Net 全帽EEG 精细分析
融合 频段权重 SFT-Net注意力 指导边缘模型

总结

  1. 双分支解耦93.8%:频谱+时序独立建模后融合
  2. 频段注意力:疲劳时θ/δ权重↑87-150%,β/γ↓43-50%
  3. 4D EEG表示:通道×频段×空间×时间四维联合
  4. 与DeltaGateNet互补:云端精细分析+边缘实时推理

https://dapalm.com/2026/09/22/2026-09-22-12-sft-net-dual-branch-spectral-temporal-eeg-ims/
作者
Mars
发布于
2026年9月22日
许可协议