mirror of https://github.com/coqui-ai/TTS.git
commet update
This commit is contained in:
parent
c36b46ee25
commit
428c224b88
|
@ -131,12 +131,12 @@ class GlowTts(nn.Module):
|
||||||
|
|
||||||
def forward(self, x, x_lengths, y=None, y_lengths=None, attn=None, g=None):
|
def forward(self, x, x_lengths, y=None, y_lengths=None, attn=None, g=None):
|
||||||
"""
|
"""
|
||||||
Shapes:
|
Shapes:
|
||||||
x: B x T
|
x: [B, T]
|
||||||
x_lenghts: B
|
x_lenghts: B
|
||||||
y: B x C x T
|
y: [B, C, T]
|
||||||
y_lengths: B
|
y_lengths: B
|
||||||
g: B x C or B
|
g: [B, C] or B
|
||||||
"""
|
"""
|
||||||
y_max_length = y.size(2)
|
y_max_length = y.size(2)
|
||||||
# norm speaker embeddings
|
# norm speaker embeddings
|
||||||
|
@ -180,7 +180,6 @@ class GlowTts(nn.Module):
|
||||||
|
|
||||||
@torch.no_grad()
|
@torch.no_grad()
|
||||||
def inference(self, x, x_lengths, g=None):
|
def inference(self, x, x_lengths, g=None):
|
||||||
|
|
||||||
if g is not None:
|
if g is not None:
|
||||||
if self.external_speaker_embedding_dim:
|
if self.external_speaker_embedding_dim:
|
||||||
g = F.normalize(g).unsqueeze(-1)
|
g = F.normalize(g).unsqueeze(-1)
|
||||||
|
|
Loading…
Reference in New Issue