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

Method forward

sovits/models.py:164–178  ·  view source on GitHub ↗
(self, x, x_mask, g=None)

Source from the content-addressed store, hash-verified

162 self.cond = nn.Conv1d(gin_channels, in_channels, 1)
163
164 def forward(self, x, x_mask, g=None):
165 x = torch.detach(x)
166 if g is not None:
167 g = torch.detach(g)
168 x = x + self.cond(g)
169 x = self.conv_1(x * x_mask)
170 x = torch.relu(x)
171 x = self.norm_1(x)
172 x = self.drop(x)
173 x = self.conv_2(x * x_mask)
174 x = torch.relu(x)
175 x = self.norm_2(x)
176 x = self.drop(x)
177 x = self.proj(x * x_mask)
178 return x * x_mask
179
180
181class TextEncoder(nn.Module):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected