Skip to content

Commit 9f23dbf

Browse files
committed
Avoid mistakenly picking Gaudi/HPU if XPU is requested.
1 parent d1fa714 commit 9f23dbf

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

setup.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -332,6 +332,8 @@ def _is_hpu() -> bool:
332332
except (ValueError, FileNotFoundError, PermissionError,
333333
subprocess.CalledProcessError):
334334
is_hpu_available = False
335+
if VLLM_TARGET_DEVICE != "hpu":
336+
return False
335337
return is_hpu_available or VLLM_TARGET_DEVICE == "hpu"
336338

337339

0 commit comments

Comments
 (0)