diff options
author | Titus von Koeller <titus@vonkoeller.com> | 2022-08-01 03:22:12 -0700 |
---|---|---|
committer | Titus von Koeller <titus@vonkoeller.com> | 2022-08-01 03:22:12 -0700 |
commit | 57fa64628f78b2f19fa31e94a9a8c59e3727888b (patch) | |
tree | 32d8bc68901e5acf7bfee43a34d706922eaaf5c2 | |
parent | 4a6ea7e24b933bf574f7707e1b331ea62f7e7273 (diff) |
minor refactor to more concise syntax
-rw-r--r-- | bitsandbytes/cuda_setup.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/bitsandbytes/cuda_setup.py b/bitsandbytes/cuda_setup.py index 08f3ed2..2fb5049 100644 --- a/bitsandbytes/cuda_setup.py +++ b/bitsandbytes/cuda_setup.py @@ -131,8 +131,7 @@ def evaluate_cuda_setup(): cc = get_compute_capability() binary_name = 'libbitsandbytes_cpu.so' - has_gpu = cc != '' - if not has_gpu: + if not (has_gpu := bool(cc)): print('WARNING: No GPU detected! Check our CUDA paths. Processing to load CPU-only library...') return binary_name |