diff options
author | Tim Dettmers <tim.dettmers@gmail.com> | 2022-08-23 13:59:34 -0700 |
---|---|---|
committer | Tim Dettmers <tim.dettmers@gmail.com> | 2022-08-23 13:59:34 -0700 |
commit | 7e0fb655e1e040221054886fbee9d5682aa6e4e2 (patch) | |
tree | ced850e90aef61e3a74a07c1933924b746cdcda6 /bitsandbytes/functional.py | |
parent | 9d60b3c5279641ba936facd710c722ebe52fcf40 (diff) |
Some initial code. Needs to be tested.
Diffstat (limited to 'bitsandbytes/functional.py')
-rw-r--r-- | bitsandbytes/functional.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/bitsandbytes/functional.py b/bitsandbytes/functional.py index 6637554..745e7e4 100644 --- a/bitsandbytes/functional.py +++ b/bitsandbytes/functional.py @@ -1686,11 +1686,10 @@ def double_quant( def get_special_format_str(): + if not torch.cuda.is_available(): return 'col_turning' major, minor = torch.cuda.get_device_capability() if major < 7: - print( - f"Device with CUDA capability of {major} not supported for 8-bit matmul. Device has no tensor cores!" - ) + print(f"Device with CUDA capability of {major} not supported for 8-bit matmul. Device has no tensor cores!") assert major >= 7 if major == 7: return 'col_turing' |