gsnn.models.SoftmaxGroupNorm
- class gsnn.models.SoftmaxGroupNorm(*args: Any, **kwargs: Any)[source]
Bases:
ModuleChannel-wise softmax normalized within each channel group (stable softmax via per-group max shift).
- __init__(channel_groups, eps=1e-08)[source]
- Parameters:
channel_groups – Length-
Cindex assigning each channel to a group.eps – Added to the denominator for numerical stability.
Methods
__init__(channel_groups[, eps])- param channel_groups:
Length-
Cindex assigning each channel to a group.
forward(x)Input
(B, C)or(B, C, 1); returns group-softmax-normalized activations.