Skip to content

Commit 36052f1

Browse files
committed
tweak linear attention
1 parent aa69b18 commit 36052f1

File tree

5 files changed

+1
-5
lines changed

5 files changed

+1
-5
lines changed

denoising_diffusion_pytorch/classifier_free_guidance.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,6 @@ def forward(self, x):
214214
k = k.softmax(dim = -1)
215215

216216
q = q * self.scale
217-
v = v / (h * w)
218217

219218
context = torch.einsum('b h d n, b h e n -> b h d e', k, v)
220219

denoising_diffusion_pytorch/denoising_diffusion_pytorch.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,6 @@ def forward(self, x):
218218
k = k.softmax(dim = -1)
219219

220220
q = q * self.scale
221-
v = v / (h * w)
222221

223222
context = torch.einsum('b h d n, b h e n -> b h d e', k, v)
224223

denoising_diffusion_pytorch/guided_diffusion.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,6 @@ def forward(self, x):
212212
k = k.softmax(dim = -1)
213213

214214
q = q * self.scale
215-
v = v / (h * w)
216215

217216
context = torch.einsum('b h d n, b h e n -> b h d e', k, v)
218217

denoising_diffusion_pytorch/simple_diffusion.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,6 @@ def forward(self, x):
187187
k = k.softmax(dim = -1)
188188

189189
q = q * self.scale
190-
v = v / (h * w)
191190

192191
context = torch.einsum('b h d n, b h e n -> b h d e', k, v)
193192

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = '1.7.3'
1+
__version__ = '1.7.4'

0 commit comments

Comments
 (0)