Closed min-hieu-netropy closed 18 hours ago
Hi, I am getting the same error on torch 2.4.1+cu121 on rtx2080.
Same problem here. torch 2.5.1+cu124 on rtx4070. I tried to manually add #include <ATen/core/Tensor.h> at the front of my local torch header "site-packages/torch/include/ATen/cuda/CUDAUtils.h" and it successfully runs. I would guess as pytorch updating, this is required at the front of slang-torch-prelude.h.
Went to try for first time, same issue here. 2.5.1 and 2.4.0 were the same error.
If I do as above and add Tensor.h to CUAUtils.h I get loads of this error:
/local/slang-torch/examples/inline-mlp-example/.slangtorch_cache/image-model/39a1e66c93673ceb/image-model.cpp:493:9: error: ‘SlangUInt’ does not name a type
I managed to make it work by adding the include directive #include <ATen/core/Tensor.h> as suggested by @Jerry-Shen0527 . For me it works either when added to CUDAUtils or to slang-torch-prelude.
This seems to be an issue triggered due to a re-ordering of #include directives in slang-torch-prelude.h
when we turned on clang-format for the main slang codebase.
Will get a fix merged & a new PR created as-soon-as-possible.
For now, please use pip install slangtorch==1.3.0
to use the previous working release, or use the workaround suggested by @Jerry-Shen0527.
I've created a new release v1.3.2
.
Can you check if updating slangtorch fixes the issue?
I've created a new release
v1.3.2
.Can you check if updating slangtorch fixes the issue?
Works for me.
The other compiler error I had related to the install in an environment (but also found something workable for now) https://github.com/shader-slang/slang-torch/issues/10
It worked perfectly! I will close this issue for now.
Hi! I'm trying to run the square example in the torch slang and got the following error
But I have no issue compiling slang before with slangpy. torch 2.5.1+cu124 running on rtx4090