Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wrap image write in try #175

Merged
merged 1 commit into from
Dec 20, 2019
Merged

wrap image write in try #175

merged 1 commit into from
Dec 20, 2019

Conversation

tripzero
Copy link
Contributor

This sometimes fails due to "Unsupported format" error.
Report the exception and move on.

train.py Outdated Show resolved Hide resolved
train.py Show resolved Hide resolved
@tripzero
Copy link
Contributor Author

Are CI failures related to the pytorch version? What can we do to get deepvoice working on the latest?

1 similar comment
@tripzero
Copy link
Contributor Author

Are CI failures related to the pytorch version? What can we do to get deepvoice working on the latest?

Copy link
Owner

@r9y9 r9y9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for the delay... Looks better now. Thank you! I will look into the CI failures later. I will merge the PR once my last comments are resolved.

train.py Outdated
mel_output = prepare_spec_image(audio._denormalize(mel_output))
writer.add_image("Predicted mel spectrogram", mel_output, global_step)
try:
mel_output = mel_outputs[idx].cpu().data.numpy()
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you move this line to the out of try block? Seems irrelevant.

train.py Outdated
Comment on lines 465 to 470
# Save averaged alignment
alignment_dir = join(checkpoint_dir, "alignment_ave")
os.makedirs(alignment_dir, exist_ok=True)
path = join(alignment_dir, "step{:09d}_layer_{}_alignment.png".format(
global_step, i + 1))
path = join(alignment_dir,
"step{:09d}_alignment.png".format(global_step))
alignment = attn.mean(0)[idx].cpu().data.numpy()
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please move the code to out of try block.

This sometimes fails due to "Unsupported format" error.
Report the exception and move on.
Copy link
Owner

@r9y9 r9y9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you so much for your contribution!!

@r9y9 r9y9 merged commit af96caf into r9y9:master Dec 20, 2019
@tripzero tripzero deleted the try_image_write branch December 21, 2019 18:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants