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 : dimension specified as 0 but tensor has no dimensions #1

Open
km1994 opened this issue May 4, 2019 · 4 comments
Open

Comments

@km1994
Copy link

km1994 commented May 4, 2019

Hello! i am reading your paper and running the code, but i have a pronlem. Can you tell me How to solve this problem "RuntimeError : dimension specified as 0 but tensor has no dimensions"? Thank you!

@ZhixiuYe
Copy link
Owner

ZhixiuYe commented May 5, 2019

Please verify the Pytorch version 0.3.0.

@90217
Copy link

90217 commented May 23, 2019

大神,针对“dimension specified as 0 but tensor has no dimensions”,可以提供下pytorch1.x的代码嘛

@liangcong64
Copy link

如果是BAGATT中的的问题,将y[0],换成torch.cuda.LongTensor([y[0]])

@shanry
Copy link

shanry commented Dec 31, 2019

我也碰到了同样的问题,但是用pytorch 0.3.1可以跑通。请问你现在知道如何改成pytorch1.x 的代码吗? @90217

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

5 participants