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

Loss is NaN on first step, if data exceeds 100 sentences #12

Open
MHamzaAhmad opened this issue Dec 19, 2021 · 3 comments
Open

Loss is NaN on first step, if data exceeds 100 sentences #12

MHamzaAhmad opened this issue Dec 19, 2021 · 3 comments

Comments

@MHamzaAhmad
Copy link

No description provided.

@MHamzaAhmad MHamzaAhmad changed the title Loss is NaN on firsr step, if data exceeds 100 sentences Loss is NaN on first step, if data exceeds 100 sentences Dec 19, 2021
@BlazJurisic
Copy link

same issue here

@mmehiretu2019
Copy link

I'm running into this issue as well. Did anyone figure out what the solution is?

@gashishoo7
Copy link

gashishoo7 commented Jan 16, 2023

@BlazJurisic and others: NaN values error may be due to pytorch version. You can check the in model.py code in tacotron2 folder. In that, check decode class, def forward, if you are using torch 1.7 then just change that as below:

#memory, mask=~get_mask_from_lengths(memory_lengths))
memory, mask=torch.logical_not(get_mask_from_lengths(memory_lengths)).type(torch.uint8)) # Use instead for torch 1.7

Hope it helps.

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

No branches or pull requests

4 participants