aboutsummaryrefslogtreecommitdiffstats
path: root/modules/hypernetworks/hypernetwork.py
diff options
context:
space:
mode:
authorAUTOMATIC <16777216c@gmail.com>2023-05-10 08:05:02 +0000
committerAUTOMATIC <16777216c@gmail.com>2023-05-10 08:05:02 +0000
commit028d3f6425d85f122027c127fba8bcbf4f66ee75 (patch)
tree05e714f118aaa4d25920918807e0b83344133629 /modules/hypernetworks/hypernetwork.py
parente42de4b8a2356c6d286adb07292442d75e5595d3 (diff)
downloadstable-diffusion-webui-gfx803-028d3f6425d85f122027c127fba8bcbf4f66ee75.tar.gz
stable-diffusion-webui-gfx803-028d3f6425d85f122027c127fba8bcbf4f66ee75.tar.bz2
stable-diffusion-webui-gfx803-028d3f6425d85f122027c127fba8bcbf4f66ee75.zip
ruff auto fixes
Diffstat (limited to 'modules/hypernetworks/hypernetwork.py')
-rw-r--r--modules/hypernetworks/hypernetwork.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/hypernetworks/hypernetwork.py b/modules/hypernetworks/hypernetwork.py
index 9fe749b7..6ef0bfdf 100644
--- a/modules/hypernetworks/hypernetwork.py
+++ b/modules/hypernetworks/hypernetwork.py
@@ -403,7 +403,7 @@ def attention_CrossAttention_forward(self, x, context=None, mask=None):
k = self.to_k(context_k)
v = self.to_v(context_v)
- q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> (b h) n d', h=h), (q, k, v))
+ q, k, v = (rearrange(t, 'b n (h d) -> (b h) n d', h=h) for t in (q, k, v))
sim = einsum('b i d, b j d -> b i j', q, k) * self.scale