Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
435b502a
"vscode:/vscode.git/clone" did not exist on "4fbcb0f27e78df75de47c0248ce6901cd081c8ff"
Unverified
Commit
435b502a
authored
Feb 18, 2025
by
Cyrus Leung
Committed by
GitHub
Feb 18, 2025
Browse files
[ROCm] Make amdsmi import optional for other platforms (#13460)
parent
29fc5772
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
vllm/platforms/rocm.py
vllm/platforms/rocm.py
+6
-2
No files found.
vllm/platforms/rocm.py
View file @
435b502a
...
...
@@ -5,8 +5,6 @@ from functools import lru_cache, wraps
from
typing
import
TYPE_CHECKING
,
Dict
,
List
,
Optional
import
torch
from
amdsmi
import
(
amdsmi_get_gpu_asic_info
,
amdsmi_get_processor_handles
,
amdsmi_init
,
amdsmi_shut_down
)
import
vllm.envs
as
envs
from
vllm.logger
import
init_logger
...
...
@@ -20,6 +18,12 @@ else:
logger
=
init_logger
(
__name__
)
try
:
from
amdsmi
import
(
amdsmi_get_gpu_asic_info
,
amdsmi_get_processor_handles
,
amdsmi_init
,
amdsmi_shut_down
)
except
ImportError
as
e
:
logger
.
warning
(
"Failed to import from amdsmi with %r"
,
e
)
try
:
import
vllm._C
# noqa: F401
except
ImportError
as
e
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment