Skip to content

Commit

Permalink
Remove nvml-specific exception check in platform determination
Browse files Browse the repository at this point in the history
  • Loading branch information
conroy-cheers authored Oct 29, 2024
1 parent da79e3e commit 400c3d1
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions vllm/platforms/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,7 @@
is_cuda = True
finally:
pynvml.nvmlShutdown()
except ImportError:
pass
except pynvml.NVMLError_LibraryNotFound:
except Exception as e:

Check failure on line 30 in vllm/platforms/__init__.py

View workflow job for this annotation

GitHub Actions / ruff (3.8)

Ruff (F841)

vllm/platforms/__init__.py:30:21: F841 Local variable `e` is assigned to but never used

Check failure on line 30 in vllm/platforms/__init__.py

View workflow job for this annotation

GitHub Actions / ruff (3.9)

Ruff (F841)

vllm/platforms/__init__.py:30:21: F841 Local variable `e` is assigned to but never used

Check failure on line 30 in vllm/platforms/__init__.py

View workflow job for this annotation

GitHub Actions / ruff (3.10)

Ruff (F841)

vllm/platforms/__init__.py:30:21: F841 Local variable `e` is assigned to but never used

Check failure on line 30 in vllm/platforms/__init__.py

View workflow job for this annotation

GitHub Actions / ruff (3.12)

Ruff (F841)

vllm/platforms/__init__.py:30:21: F841 Local variable `e` is assigned to but never used
# CUDA is supported on Jetson, but NVML is not.
import os

Expand All @@ -40,8 +38,6 @@ def cuda_is_jetson() -> bool:
if cuda_is_jetson():
is_cuda = True
is_cuda_jetson = True
except Exception:
pass

is_rocm = False

Expand Down

0 comments on commit 400c3d1

Please sign in to comment.