espnet2.gan_tts.parallel_wavegan.upsample.ConvInUpsampleNetwork
Less than 1 minute
espnet2.gan_tts.parallel_wavegan.upsample.ConvInUpsampleNetwork
class espnet2.gan_tts.parallel_wavegan.upsample.ConvInUpsampleNetwork(upsample_scales: List[int], nonlinear_activation: str | None = None, nonlinear_activation_params: Dict[str, Any] = {}, interpolate_mode: str = 'nearest', freq_axis_kernel_size: int = 1, aux_channels: int = 80, aux_context_window: int = 0)
Bases: Module
Convolution + upsampling network module.
Initialize ConvInUpsampleNetwork module.
- Parameters:
- upsample_scales (list) – List of upsampling scales.
- nonlinear_activation (Optional *[*str ]) – Activation function name.
- nonlinear_activation_params (Dict *[*str , Any ]) – Arguments for the specified activation function.
- mode (str) – Interpolation mode.
- freq_axis_kernel_size (int) – Kernel size in the direction of frequency axis.
- aux_channels (int) – Number of channels of pre-conv layer.
- aux_context_window (int) – Context window size of the pre-conv layer.
forward(c: Tensor) → Tensor
Calculate forward propagation.
- Parameters:c (Tensor) – Input tensor (B, C, T_feats).
- Returns: Upsampled tensor (B, C, T_wav), : where T_wav = T_feats * prod(upsample_scales).
- Return type: Tensor