rxnn 0.1.78__py3-none-any.whl → 0.1.79__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -40,8 +40,8 @@ class RotaryPositionalEmbedding(nn.Module):
40
40
  return q_embed
41
41
 
42
42
  def _prepare_freqs(self, seq_len: int, device: torch.device) -> torch.Tensor:
43
- cache_len = self.cache.size(1)
44
- if self.cache is None or cache_len < seq_len:
43
+ cache_len = self.cache.size(1) if self.cache is not None else 0
44
+ if cache_len < seq_len:
45
45
  t = torch.arange(seq_len, device=device).type_as(self.inv_freq)
46
46
  freqs = torch.einsum('i,j->ij', t, self.inv_freq)
47
47
  self.cache = freqs
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: rxnn
3
- Version: 0.1.78
3
+ Version: 0.1.79
4
4
  Summary: RxNN: Reactive Neural Networks Platform
5
5
  License: Apache-2.0
6
6
  Keywords: deep-learning,ai,machine-learning
@@ -22,10 +22,10 @@ rxnn/transformers/layers.py,sha256=OX8CsFY9A7uqH1SLwyexR_5BNlwheYrJHCGXjF8Q7HU,7
22
22
  rxnn/transformers/mask.py,sha256=J0cfLVLt3SzS2ra3KcY4khrkhI975Dw4CjpUi3Sn25s,419
23
23
  rxnn/transformers/models.py,sha256=xbnn3FTNZFhaqq9A0XEM12ie_WL_58pPeq0qFXIgve0,7656
24
24
  rxnn/transformers/moe.py,sha256=j6jEx6Ip0zttlUZKKn82azxo95lkLZs-H2GLSMD88hY,5859
25
- rxnn/transformers/positional.py,sha256=DE1TP3D6ikBPg3Ym0sP9F666LHuE70H0w-JEH5DfKPw,4415
25
+ rxnn/transformers/positional.py,sha256=NxzXSK_BS2doojaFVNpjoUk9lNX6WNQUBu_TR2HFKe4,4426
26
26
  rxnn/transformers/sampler.py,sha256=poWBpxg1iuK5gEJtxHkk5VVfS9V48hs2Olqdhy_Gw8c,6548
27
27
  rxnn/utils.py,sha256=d5U8i5ukovgDyqiycc2AoxObTz_eF_bgo2MKvdtJ98s,467
28
- rxnn-0.1.78.dist-info/LICENSE,sha256=C8coDFIUYuOcke4JLPwTqahQUCyXyGq6WOaigOkx8tY,11275
29
- rxnn-0.1.78.dist-info/METADATA,sha256=559E3b22oEiu6vXNnsi7xLCw0GeuYQmcdmOgHkcdlL0,16589
30
- rxnn-0.1.78.dist-info/WHEEL,sha256=fGIA9gx4Qxk2KDKeNJCbOEwSrmLtjWCwzBz351GyrPQ,88
31
- rxnn-0.1.78.dist-info/RECORD,,
28
+ rxnn-0.1.79.dist-info/LICENSE,sha256=C8coDFIUYuOcke4JLPwTqahQUCyXyGq6WOaigOkx8tY,11275
29
+ rxnn-0.1.79.dist-info/METADATA,sha256=xbeo3W1b7ojEZq3qqJ3HnNkx3LUZABDQVfMIDvoLSB0,16589
30
+ rxnn-0.1.79.dist-info/WHEEL,sha256=fGIA9gx4Qxk2KDKeNJCbOEwSrmLtjWCwzBz351GyrPQ,88
31
+ rxnn-0.1.79.dist-info/RECORD,,
File without changes
File without changes