-
Notifications
You must be signed in to change notification settings - Fork 143
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
Causal model running on GPU #7
Comments
@Warvito ahh, so not often spoken about is the fact that the auto-regressive flavor of linear attention actually incurs a pretty big memory cost (x sequence length) and requires special CUDA code to be performant (it is probably why google chose to do this in Jax) EPFL wrote up a nice implementation, but i think it is somehow failing to be imported on your machine https://github.com/idiap/fast-transformers/blob/master/fast_transformers/causal_product/__init__.py#L12 |
@Warvito could you try python-ing into the interactive session and run > import fast_transformers.causal_product.causal_product_cuda and see what happens? |
@lucidrains Thank you for the quick reply. I tried the command that you asked and I got the following error:
I have the 0.3.0 version installed here, and it works as expected when using casual=False. I had the chance to try also in a system with a V100 and CUDA 11. And it worked as expected. Thank you again for the quick reply, and thank you very much for all your repositories. ^^ |
@Warvito I'm in the dark as much as you are :( I have been putting off custom CUDA code for as long as I could, but the results of this paper was irresistible |
I had the same issue. I am not sure what worked for me but after some steps training with casual=True is working. my steps:
|
@arti32lehtonen is right, make sure c++ tool chain (gcc) and cuda tool chain (nvcc) is available in your environment. If not, use export command make it visible (try "nvcc --version" after that), then reinstall the package. |
Thx @arti32lehtonen and @yygle ! |
Hi, I am trying to run the LM model with the
causal = True
on the GPU but I am getting some issues.I am trying to run the following example:
And I am getting this error:
My system has:
TITAN RTX
CUDA Version: 10.2
Driver Version: 440.100
The text was updated successfully, but these errors were encountered: