mirror of
https://git.datalinker.icu/comfyanonymous/ComfyUI
synced 2026-10-04 00:07:12 +08:00
fixed missing closing bracket
This commit is contained in:
parent
938f824aae
commit
438b1ea399
@ -260,7 +260,7 @@ def attention_split(q, k, v, heads, mask=None, attn_precision=None):
|
|||||||
end = i + slice_size
|
end = i + slice_size
|
||||||
if upcast:
|
if upcast:
|
||||||
with torch.autocast(enabled=False, device_type = 'cuda'):
|
with torch.autocast(enabled=False, device_type = 'cuda'):
|
||||||
s1 = einsum('b i d, b j d -> b i j', q[:, i:end].to(dtype=torch.float32), k.to(dtype=torch.float32) * scale
|
s1 = einsum('b i d, b j d -> b i j', q[:, i:end].to(dtype=torch.float32), k.to(dtype=torch.float32)) * scale
|
||||||
else:
|
else:
|
||||||
s1 = einsum('b i d, b j d -> b i j', q[:, i:end], k) * scale
|
s1 = einsum('b i d, b j d -> b i j', q[:, i:end], k) * scale
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user