rxnn 0.2.0__py3-none-any.whl → 0.2.1__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.
rxnn/memory/stm.py
CHANGED
@@ -14,14 +14,16 @@ class ShortTermMemory(nn.Module):
|
|
14
14
|
self.is_trainable = is_trainable
|
15
15
|
assert init_type in ['normal', 'standard', 'uniform', 'ones', 'zeros'], \
|
16
16
|
'STM init type must be one of "normal", "standard", "uniform", "ones", "zeros"'
|
17
|
+
|
18
|
+
# Legacy init - temporary option to load old models with not-batched STM (they will be loaded, updated and then the option will be removed)
|
19
|
+
self.legacy_init = legacy_init
|
20
|
+
|
17
21
|
self.init_type = init_type
|
18
22
|
stm = self._init_tensor()
|
19
23
|
if self.is_trainable:
|
20
24
|
self.memory = nn.Parameter(stm)
|
21
25
|
else:
|
22
26
|
self.register_buffer('memory', stm)
|
23
|
-
# Legacy init - temporary option to load old models with not-batched STM (they will be loaded, updated and then the option will be removed)
|
24
|
-
self.legacy_init = legacy_init
|
25
27
|
|
26
28
|
def _init_tensor(self, init_type: str = None):
|
27
29
|
init_type = init_type or self.init_type
|
@@ -7,7 +7,7 @@ rxnn/experimental/moe.py,sha256=jHZ1QhpWiVQOswVpFmuH7b2IUOPf0Uuf-I2Ddwsd7Us,6140
|
|
7
7
|
rxnn/memory/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
8
8
|
rxnn/memory/attention.py,sha256=p-r8DK3iVhNn-JAESVzIXDCG8gk1R_-x5xHclZ5jgb0,1813
|
9
9
|
rxnn/memory/norm.py,sha256=Ofl8Q5NYEF9GQeO0bhM43tkTW91J0y6TSvTAOYMgloM,6278
|
10
|
-
rxnn/memory/stm.py,sha256=
|
10
|
+
rxnn/memory/stm.py,sha256=tEAC5c4QPl-ykNm-k2DlcP6Q2NQKGXMnpKLCx92lI30,4083
|
11
11
|
rxnn/rxt/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
12
12
|
rxnn/rxt/models.py,sha256=zNrf6mn-s2vJyauHwNgYm_e-gFI1clmXp_JyCKGQD3E,12083
|
13
13
|
rxnn/training/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -32,7 +32,7 @@ rxnn/transformers/moe.py,sha256=j6jEx6Ip0zttlUZKKn82azxo95lkLZs-H2GLSMD88hY,5859
|
|
32
32
|
rxnn/transformers/positional.py,sha256=1PjcJybUzeQlIKJI4tahAGZcYgCRCL0otxs7mpsNuzM,4410
|
33
33
|
rxnn/transformers/sampler.py,sha256=2dpUQv88ekZa_CMSPLrXvB6X684wxUE2bDVznsi5ACs,17429
|
34
34
|
rxnn/utils.py,sha256=ihb6OTyDtPiocB_lOvnq7eOkjjpCkgs8wxvXUBNQ7mM,996
|
35
|
-
rxnn-0.2.
|
36
|
-
rxnn-0.2.
|
37
|
-
rxnn-0.2.
|
38
|
-
rxnn-0.2.
|
35
|
+
rxnn-0.2.1.dist-info/LICENSE,sha256=C8coDFIUYuOcke4JLPwTqahQUCyXyGq6WOaigOkx8tY,11275
|
36
|
+
rxnn-0.2.1.dist-info/METADATA,sha256=0NaOW0HNG4nGR3Vchlp-vlzzx7NBSFpAPFYwGzT3qP8,25959
|
37
|
+
rxnn-0.2.1.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
|
38
|
+
rxnn-0.2.1.dist-info/RECORD,,
|
File without changes
|
File without changes
|