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

Issue building prefix_sum #2

Closed
yuhao opened this issue Jun 25, 2021 · 2 comments
Closed

Issue building prefix_sum #2

yuhao opened this issue Jun 25, 2021 · 2 comments

Comments

@yuhao
Copy link

yuhao commented Jun 25, 2021

gcc/g++ version 6.5.0
nvcc version 10.0
Python 3.6.8
on centos 7.9

trying to build prefix_sum and got the following. Any suggestion is appreciated!

prefix_sum.cu(80): error: a pointer to a bound function may only be used to call the function

prefix_sum.cu(80): error: type name is not allowed

prefix_sum.cu(80): error: expected an expression

prefix_sum.cu(81): error: a pointer to a bound function may only be used to call the function

prefix_sum.cu(81): error: type name is not allowed

prefix_sum.cu(81): error: expected an expression

prefix_sum.cu(95): error: a pointer to a bound function may only be used to call the function

prefix_sum.cu(95): error: type name is not allowed

prefix_sum.cu(95): error: expected an expression

prefix_sum.cu(96): error: a pointer to a bound function may only be used to call the function

prefix_sum.cu(96): error: type name is not allowed

prefix_sum.cu(96): error: expected an expression
@lxxue
Copy link
Owner

lxxue commented Jun 25, 2021

Mine works with gcc/g++ 7.5.0, cuda 10.2 (10.1 should also works) and python 3.8.2 on ubuntu 18.04. Will check it out after a report deadline in several hours...
scan( grid_off.contiguous().data_ptr<int>(), grid_cnt.contiguous().data_ptr<int>(), num_grids, true );
The code looks fine to me. I use this conversion from at::Tensor to type* throughout the library. Maybe you can check your pytorch version? Mine is 1.6.0 and it is working.

@yuhao
Copy link
Author

yuhao commented Jun 25, 2021

Hmm update pytorch to 1.8 seems to do the trick. Thanks.

@yuhao yuhao closed this as completed Jun 25, 2021
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