Browse Source

logger.py: compatibility with new tensorboardX

master
Rafael Valle 5 years ago
parent
commit
37a033de6f
1 changed files with 4 additions and 4 deletions
  1. +4
    -4
      logger.py

+ 4
- 4
logger.py View File

@ -31,18 +31,18 @@ class Tacotron2Logger(SummaryWriter):
self.add_image( self.add_image(
"alignment", "alignment",
plot_alignment_to_numpy(alignments[idx].data.cpu().numpy().T), plot_alignment_to_numpy(alignments[idx].data.cpu().numpy().T),
iteration)
iteration, dataformats='HWC')
self.add_image( self.add_image(
"mel_target", "mel_target",
plot_spectrogram_to_numpy(mel_targets[idx].data.cpu().numpy()), plot_spectrogram_to_numpy(mel_targets[idx].data.cpu().numpy()),
iteration)
iteration, dataformats='HWC')
self.add_image( self.add_image(
"mel_predicted", "mel_predicted",
plot_spectrogram_to_numpy(mel_outputs[idx].data.cpu().numpy()), plot_spectrogram_to_numpy(mel_outputs[idx].data.cpu().numpy()),
iteration)
iteration, dataformats='HWC')
self.add_image( self.add_image(
"gate", "gate",
plot_gate_outputs_to_numpy( plot_gate_outputs_to_numpy(
gate_targets[idx].data.cpu().numpy(), gate_targets[idx].data.cpu().numpy(),
torch.sigmoid(gate_outputs[idx]).data.cpu().numpy()), torch.sigmoid(gate_outputs[idx]).data.cpu().numpy()),
iteration)
iteration, dataformats='HWC')

Loading…
Cancel
Save