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

only one element tensors can be converted to Python scalars #20

Closed
Chang-007 opened this issue Sep 6, 2022 · 1 comment
Closed

only one element tensors can be converted to Python scalars #20

Chang-007 opened this issue Sep 6, 2022 · 1 comment

Comments

@Chang-007
Copy link

Thank you very much for your work, and I am getting errors like this during training:
only one element tensors can be converted to Python scalars
0582950fbc7fdecb442b400e201b66e

It can be trained normally at the beginning, but this error is reported after a few hundred iters. Have you ever met? HELP

@iris0329
Copy link
Collaborator

iris0329 commented Sep 20, 2022

Hmm, that's werid, can you print the value of loss_lov.item() and input_feature.size(0).

A quickly suggestion is to comment this line, because it's just a logger of loss value, it won't effect the training process.

Best

@iris0329 iris0329 closed this as completed Dec 6, 2022
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

2 participants