espnet2.gan_tts.vits.flow.DilatedDepthSeparableConv
Less than 1 minute
espnet2.gan_tts.vits.flow.DilatedDepthSeparableConv
class espnet2.gan_tts.vits.flow.DilatedDepthSeparableConv(channels: int, kernel_size: int, layers: int, dropout_rate: float = 0.0, eps: float = 1e-05)
Bases: Module
Dilated depth-separable conv module.
Initialize DilatedDepthSeparableConv module.
- Parameters:
- channels (int) – Number of channels.
- kernel_size (int) – Kernel size.
- layers (int) – Number of layers.
- dropout_rate (float) – Dropout rate.
- eps (float) – Epsilon for layer norm.
forward(x: Tensor, x_mask: Tensor, g: Tensor | None = None) → Tensor
Calculate forward propagation.
- Parameters:
- x (Tensor) – Input tensor (B, in_channels, T).
- x_mask (Tensor) – Mask tensor (B, 1, T).
- g (Optional *[*Tensor ]) – Global conditioning tensor (B, global_channels, 1).
- Returns: Output tensor (B, channels, T).
- Return type: Tensor