MCPcopy Create free account
hub / github.com/MYZY-AI/Muyan-TTS / __init__

Method __init__

sovits/module/modules.py:321–347  ·  view source on GitHub ↗
(self, channels, kernel_size=3, dilation=(1, 3))

Source from the content-addressed store, hash-verified

319
320class ResBlock2(torch.nn.Module):
321 def __init__(self, channels, kernel_size=3, dilation=(1, 3)):
322 super(ResBlock2, self).__init__()
323 self.convs = nn.ModuleList(
324 [
325 weight_norm(
326 Conv1d(
327 channels,
328 channels,
329 kernel_size,
330 1,
331 dilation=dilation[0],
332 padding=get_padding(kernel_size, dilation[0]),
333 )
334 ),
335 weight_norm(
336 Conv1d(
337 channels,
338 channels,
339 kernel_size,
340 1,
341 dilation=dilation[1],
342 padding=get_padding(kernel_size, dilation[1]),
343 )
344 ),
345 ]
346 )
347 self.convs.apply(init_weights)
348
349 def forward(self, x, x_mask=None):
350 for c in self.convs:

Callers

nothing calls this directly

Calls 2

get_paddingFunction · 0.90
__init__Method · 0.45

Tested by

no test coverage detected