metacontroller-pytorch 0.0.27__tar.gz → 0.0.28__tar.gz
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.
Potentially problematic release.
This version of metacontroller-pytorch might be problematic. Click here for more details.
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/PKG-INFO +1 -1
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/metacontroller/metacontroller_with_binary_mapper.py +3 -1
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/pyproject.toml +1 -1
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/.github/workflows/python-publish.yml +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/.github/workflows/test.yml +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/.gitignore +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/LICENSE +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/README.md +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/fig1.png +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/gather_babyai_trajs.py +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/metacontroller/__init__.py +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/metacontroller/metacontroller.py +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/test_babyai_e2e.sh +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/tests/test_metacontroller.py +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/train_babyai.py +0 -0
- {metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/train_behavior_clone_babyai.py +0 -0
|
@@ -23,7 +23,7 @@ from x_mlps_pytorch import Feedforwards
|
|
|
23
23
|
|
|
24
24
|
from assoc_scan import AssocScan
|
|
25
25
|
|
|
26
|
-
from torch_einops_utils import maybe, pad_at_dim, lens_to_mask
|
|
26
|
+
from torch_einops_utils import maybe, pad_at_dim, lens_to_mask, align_dims_left
|
|
27
27
|
from torch_einops_utils.save_load import save_load
|
|
28
28
|
|
|
29
29
|
from vector_quantize_pytorch import BinaryMapper
|
|
@@ -220,6 +220,8 @@ class MetaControllerWithBinaryMapper(Module):
|
|
|
220
220
|
if discovery_phase:
|
|
221
221
|
# weight unreduced kl loss by switch gates
|
|
222
222
|
|
|
223
|
+
kl_loss, switch_beta = align_dims_left((kl_loss, switch_beta))
|
|
224
|
+
|
|
223
225
|
weighted_kl_loss = kl_loss * switch_beta
|
|
224
226
|
kl_loss = weighted_kl_loss.sum(dim = -1).mean()
|
|
225
227
|
|
{metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/.github/workflows/python-publish.yml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/metacontroller/metacontroller.py
RENAMED
|
File without changes
|
|
File without changes
|
{metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/tests/test_metacontroller.py
RENAMED
|
File without changes
|
|
File without changes
|
{metacontroller_pytorch-0.0.27 → metacontroller_pytorch-0.0.28}/train_behavior_clone_babyai.py
RENAMED
|
File without changes
|