espnet.nets.pytorch_backend.conformer.convolution.ConvolutionModule
Less than 1 minute
espnet.nets.pytorch_backend.conformer.convolution.ConvolutionModule
class espnet.nets.pytorch_backend.conformer.convolution.ConvolutionModule(channels, kernel_size, activation=ReLU(), bias=True)
Bases: Module
ConvolutionModule in Conformer model.
- Parameters:
- channels (int) – The number of channels of conv layers.
- kernel_size (int) – Kernerl size of conv layers.
Construct an ConvolutionModule object.
forward(x)
Compute convolution module.
- Parameters:x (torch.Tensor) – Input tensor (#batch, time, channels).
- Returns: Output tensor (#batch, time, channels).
- Return type: torch.Tensor