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

RuntimeError: indices should be either on cpu or on the same device as the indexed tensor (cpu) #125

Open
WZY009 opened this issue Dec 16, 2024 · 1 comment

Comments

@WZY009
Copy link

WZY009 commented Dec 16, 2024

能请问一下为什么跑自己的训练集就会出现这种问题吗

@WZY009
Copy link
Author

WZY009 commented Dec 16, 2024

如果将model/rnn.py line 83的cpu()给去掉,则会出现: RuntimeError: 'lengths' argument should be a 1D CPU int64 tensor, but got 1D cuda:0 Long tensor

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

1 participant