diff --git a/layers/tacotron.py b/layers/tacotron.py index 8c545c90..c5b1d2ff 100644 --- a/layers/tacotron.py +++ b/layers/tacotron.py @@ -305,8 +305,7 @@ class Decoder(nn.Module): if t > inputs.shape[1]/2 and stop_token > 0.6: break elif t > self.max_decoder_steps: - print(" !! Decoder stopped with 'max_decoder_steps'. \ - Something is probably wrong.") + print(" | | > Decoder stopped with 'max_decoder_steps") break assert greedy or len(outputs) == T_decoder # Back to batch first diff --git a/train.py b/train.py index c93607df..f1e35e15 100644 --- a/train.py +++ b/train.py @@ -301,7 +301,7 @@ def evaluate(model, criterion, criterion_st, data_loader, ap, current_step): # test sentences ap.griffin_lim_iters = 60 for idx, test_sentence in enumerate(test_sentences): - wav, linear_out, alignments = synthesis(model, ap, test_sentence, use_cuda, + wav, linear_spec, alignments = synthesis(model, ap, test_sentence, use_cuda, c.text_cleaner) try: wav_name = 'TestSentences/{}'.format(idx) @@ -310,10 +310,9 @@ def evaluate(model, criterion, criterion_st, data_loader, ap, current_step): except: pass align_img = alignments[0].data.cpu().numpy() - linear_spec = linear_output[0].data.cpu().numpy() linear_spec = plot_spectrogram(linear_spec, ap) align_img = plot_alignment(align_img) - tb.add_image('TestSentences/{}_GroundTruth'.format(idx), gt_spec, current_step) + tb.add_image('TestSentences/{}_Spectrogram'.format(idx), linear_spec, current_step) tb.add_image('TestSentences/{}_Alignment'.format(idx), align_img, current_step) return avg_linear_loss