Rename utils due to name conflict

This commit is contained in:
Eren 2018-07-05 17:02:14 +02:00
parent bdf3fd209a
commit 83707b4b93
1 changed files with 2 additions and 4 deletions

View File

@ -14,7 +14,7 @@ def create_speech(m, s, CONFIG, use_cuda, ap):
chars_var = torch.from_numpy(seq).unsqueeze(0)
if use_cuda:
chars_var = chars_var.cuda()
mel_out, linear_out, alignments, stop_tokens = m.forward(chars_var)
mel_out, linear_out, alignments, stop_tokens = m.forward(chars_var.long())
linear_out = linear_out[0].data.cpu().numpy()
alignment = alignments[0].cpu().data.numpy()
spec = ap._denormalize(linear_out)
@ -46,5 +46,3 @@ def visualize(alignment, spectrogram, stop_tokens, CONFIG):
plt.ylabel("Hz", fontsize=label_fontsize)
plt.tight_layout()
plt.colorbar()