espnet2.gan_codec.shared.encoder.seanet.SLSTM
Less than 1 minute
espnet2.gan_codec.shared.encoder.seanet.SLSTM
class espnet2.gan_codec.shared.encoder.seanet.SLSTM(dimension: int, num_layers: int = 2, skip: bool = True)
Bases: Module
LSTM without worrying about the hidden state, nor the layout of the data. Expects input as convolutional layout.
Initializes internal Module state, shared by both nn.Module and ScriptModule.
forward(x)
Defines the computation performed at every call.
Should be overridden by all subclasses.
NOTE
Although the recipe for forward pass needs to be defined within this function, one should call the Module
instance afterwards instead of this since the former takes care of running the registered hooks while the latter silently ignores them.