gluonts.mx.block.sndense module

class gluonts.mx.block.sndense.SNDense(units: int, in_units: int, coeff: float = 0.9, activation: Optional[str] = None, use_bias: bool = True, flatten: bool = True, weight_initializer: mxnet.initializer.Initializer = <mxnet.initializer.Orthogonal object>, bias_initializer='zeros', dtype='float32', num_power_iter: int = 1, ctx: Optional[mxnet.context.Context] = None, **kwargs)[source]

Bases: mxnet.gluon.block.HybridBlock

Dense layer with spectral normalization applied to weights, as in [BJC19].

hybrid_forward(F, x, _weight, _u, _bias=None)[source]
Parameters

x – Input Tensor of SNDense layer

Returns

Output Tensor of SNDense layer

Return type

Tensor

property weight