Skip to content

Commit

Permalink
address #29
Browse files Browse the repository at this point in the history
  • Loading branch information
lucidrains committed Feb 27, 2024
1 parent 264a1f2 commit fbd8333
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
setup(
name = 'soundstorm-pytorch',
packages = find_packages(exclude=[]),
version = '0.4.1',
version = '0.4.2',
license='MIT',
description = 'SoundStorm - Efficient Parallel Audio Generation from Google Deepmind, in Pytorch',
author = 'Phil Wang',
Expand Down
2 changes: 1 addition & 1 deletion soundstorm_pytorch/soundstorm.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ def get_mask_subset_prob(
logits = torch.rand((batch, seq), device = device)
logits = logits.masked_fill(~mask, -1)

randperm = logits.argsort(dim = -1).float()
randperm = logits.argsort(dim = -1).argsort(dim = -1).float()

num_padding = (~mask).sum(dim = -1, keepdim = True)
randperm -= num_padding
Expand Down

0 comments on commit fbd8333

Please sign in to comment.