Skip to content

Commit

Permalink
[build] build against installed cuda-11.1 while torch built w/ cuda-1…
Browse files Browse the repository at this point in the history
…1.0 (microsoft#570)
  • Loading branch information
stas00 authored Dec 3, 2020
1 parent be33bea commit ff58fa7
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions op_builder/builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ def assert_no_cuda_mismatch():
torch_cuda_version = ".".join(torch.version.cuda.split('.')[:2])
# This is a show-stopping error, should probably not proceed past this
if sys_cuda_version != torch_cuda_version:
if sys_cuda_version == "11.1" and torch_cuda_version == "11.0":
# it works to build against installed cuda-11.1 while torch was built with cuda-11.0
return
raise Exception(
f"Installed CUDA version {sys_cuda_version} does not match the "
f"version torch was compiled with {torch.version.cuda}, unable to compile "
Expand Down

0 comments on commit ff58fa7

Please sign in to comment.