-
Notifications
You must be signed in to change notification settings - Fork 52
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
[Bug] binary arithmetic with CUDA scalar #95
Comments
Thanks @soodoshll! |
KTong821
added a commit
to KTong821/hidet
that referenced
this issue
Apr 24, 2024
Stable diffusion uses fundamentally the same positional embeddings, but since timesteps change, a cache is not possible. There's also small changes in tensor layouts and calculation parameters between the diffusers version and the one from Llama, so I've recreated it here for now. An abstract version that combines both version is TODO. Towards hidet-org#57.
vadiklyutiy
pushed a commit
that referenced
this issue
Jul 22, 2024
Stable diffusion uses fundamentally the same positional embeddings, but since timesteps change, a cache is not possible. There's also small changes in tensor layouts and calculation parameters between the diffusers version and the one from Llama, so I've recreated it here for now. An abstract version that combines both version is TODO. Towards #57.
vadiklyutiy
pushed a commit
that referenced
this issue
Jul 23, 2024
Stable diffusion uses fundamentally the same positional embeddings, but since timesteps change, a cache is not possible. There's also small changes in tensor layouts and calculation parameters between the diffusers version and the one from Llama, so I've recreated it here for now. An abstract version that combines both version is TODO. Towards #57.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In
hidet/python/hidet/graph/ops/definitions/arithmetic.py
Line 486 in 80a35d6
It looks like in order to calculate a binary operator with a scalar on GPU, we need to first copy it to CPU (Is it expected? Will it affect the performance because of synchronization?). And the
cpu()
function raises an error saying we should firstdetach
the variable inhidet/python/hidet/graph/tensor.py
Line 486 in 80a35d6
If we add
detach
here, here comes the second problem. It looks like the.numpy
(or to_dlpack) method does not support a tensor with only one element and shape []. The error message is like:The text was updated successfully, but these errors were encountered: