braindecode.modules.ECA#

class braindecode.modules.ECA(in_channels: int, kernel_size: int)[source]#

Efficient Channel Attention [Wang2021].

Parameters:
  • in_channels (int) – number of input feature channels

  • kernel_size (int) – kernel size of convolutional layer, determines degree of channel interaction, must be odd.

References

[Wang2021]

Wang, Q. et al., 2021. ECA-Net: Efficient Channel Attention

for Deep Convolutional Neural Networks. CVPR 2021.

Methods

forward(x)[source]#

Apply the Efficient Channel Attention block to the input tensor.

Parameters:

x (Pytorch.Tensor)

Return type:

Pytorch.Tensor