Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
ComfyUI
Commits
321c5fa2
Commit
321c5fa2
authored
Sep 17, 2023
by
comfyanonymous
Browse files
Enable pytorch attention by default on xpu.
parent
0665749b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
comfy/model_management.py
comfy/model_management.py
+3
-0
No files found.
comfy/model_management.py
View file @
321c5fa2
...
@@ -165,6 +165,9 @@ try:
...
@@ -165,6 +165,9 @@ try:
ENABLE_PYTORCH_ATTENTION
=
True
ENABLE_PYTORCH_ATTENTION
=
True
if
torch
.
cuda
.
is_bf16_supported
():
if
torch
.
cuda
.
is_bf16_supported
():
VAE_DTYPE
=
torch
.
bfloat16
VAE_DTYPE
=
torch
.
bfloat16
if
is_intel_xpu
():
if
args
.
use_split_cross_attention
==
False
and
args
.
use_quad_cross_attention
==
False
:
ENABLE_PYTORCH_ATTENTION
=
True
except
:
except
:
pass
pass
...
...
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