MCPcopy Create free account
hub / github.com/FireRedTeam/FireRedTTS2 / __init__

Method __init__

fireredtts2/codec/decoder.py:79–86  ·  view source on GitHub ↗
(
        self,
        in_channels: int,
        out_channels: int,
        kernel_size: int,
    )

Source from the content-addressed store, hash-verified

77# A causal variant of Conv1d
78class CausalConv1d(torch.nn.Conv1d):
79 def __init__(
80 self,
81 in_channels: int,
82 out_channels: int,
83 kernel_size: int,
84 ) -> None:
85 super(CausalConv1d, self).__init__(in_channels, out_channels, kernel_size)
86 self.causal_padding = (kernel_size - 1, 0)
87
88 def forward(self, x: torch.Tensor):
89 x = F.pad(x, self.causal_padding)

Callers

nothing calls this directly

Calls 1

__init__Method · 0.45

Tested by

no test coverage detected