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
7caec10e
Unverified
Commit
7caec10e
authored
Aug 16, 2025
by
Kunshang Ji
Committed by
GitHub
Aug 16, 2025
Browse files
[XPU]avoid circular import during XPU init (#23017)
Signed-off-by:
Kunshang Ji
<
kunshang.ji@intel.com
>
parent
1f83e7d8
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
vllm/platforms/xpu.py
vllm/platforms/xpu.py
+2
-1
No files found.
vllm/platforms/xpu.py
View file @
7caec10e
...
@@ -7,7 +7,6 @@ from typing import TYPE_CHECKING, Optional
...
@@ -7,7 +7,6 @@ from typing import TYPE_CHECKING, Optional
import
torch
import
torch
import
vllm.envs
as
envs
import
vllm.envs
as
envs
from
vllm.config
import
CUDAGraphMode
from
vllm.logger
import
init_logger
from
vllm.logger
import
init_logger
from
vllm.utils
import
DEFAULT_MAX_NUM_BATCHED_TOKENS
from
vllm.utils
import
DEFAULT_MAX_NUM_BATCHED_TOKENS
...
@@ -105,6 +104,8 @@ class XPUPlatform(Platform):
...
@@ -105,6 +104,8 @@ class XPUPlatform(Platform):
and
not
cls
.
device_support_bf16
():
and
not
cls
.
device_support_bf16
():
model_config
.
dtype
=
torch
.
float16
model_config
.
dtype
=
torch
.
float16
# lazy import to avoid circular import
from
vllm.config
import
CUDAGraphMode
compilation_config
=
vllm_config
.
compilation_config
compilation_config
=
vllm_config
.
compilation_config
if
compilation_config
.
cudagraph_mode
is
None
or
\
if
compilation_config
.
cudagraph_mode
is
None
or
\
compilation_config
.
cudagraph_mode
.
max_cudagraph_mode
()
\
compilation_config
.
cudagraph_mode
.
max_cudagraph_mode
()
\
...
...
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