Skip to content

Commit 33c380d

Browse files
committed
commit loss was reduced over batch already
1 parent 6c1b726 commit 33c380d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
setup(
44
name = 'vector_quantize_pytorch',
55
packages = find_packages(),
6-
version = '0.10.9',
6+
version = '0.10.10',
77
license='MIT',
88
description = 'Vector Quantization - Pytorch',
99
long_description_content_type = 'text/markdown',

vector_quantize_pytorch/residual_vq.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ def forward(
8484

8585
if should_quantize_dropout and quantizer_index > rand_quantize_dropout_index:
8686
null_indices = torch.full((b, n), -1., device = device, dtype = torch.long)
87-
null_loss = torch.full((b,), 0., device = device, dtype = x.dtype)
87+
null_loss = torch.full((1,), 0., device = device, dtype = x.dtype)
8888

8989
all_indices.append(null_indices)
9090
all_losses.append(null_loss)

0 commit comments

Comments
 (0)