-
Notifications
You must be signed in to change notification settings - Fork 26.3k
Add torch.backends.cudnn.is_available #8703
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
Conversation
test/common_cuda.py
Outdated
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
676f2f7 to
fb81212
Compare
|
Why is this under I'm asking because I'm adding some cuFFT specific methods in #8344 and want to know where they should live. |
|
Yeah, why are we duplicating this? We have |
|
@apaszke I don't think this function you mention exists? I don't mind where it lives, just let me know what you would prefer |
|
@apaszke we only have |
fb81212 to
ab20813
Compare
|
done |
|
Hmm ok, I could swear it exists 😕 Adding it sounds good to me |
Some users are using
torch._C.has_cudnnto determine if cudnn is available (e.g. https://github.com/pytorch/pytorch/pull/8313/files#diff-52a3dcb763bfba3076c1cc8aef9b1e72R17). There should probably be a friendlier way of doing this. This PR adds this function.Please advise if
torch._C.has_cudnnis ok, or bettertorch.backends.cudnn.is_acceptable(torch.tensor(1., device=CUDA_DEVICE))which I've seen in other code.@soumith @apaszke @colesbury