SCSEModule¶

class SCSEModule(in_channels, reduction=16)[source]¶

Spatial and Channel Squeeze & Excitation (SCSE) module.

Initialize the SCSE module.

Parameters:
  • in_channels (int) – Number of input channels.

  • reduction (int) – Reduction ratio for channel attention.

Methods

forward

Forward pass of the SCSE module.

Attributes

training

forward(x)[source]¶

Forward pass of the SCSE module.

Parameters:
Returns:

Output feature map after applying SCSE attention.

Return type:

torch.Tensor