Skip to content

Commit 22033ca

Browse files
committed
Forgot a minus and accidentally added the model
1 parent c057132 commit 22033ca

File tree

3 files changed

+2
-2
lines changed

3 files changed

+2
-2
lines changed
Binary file not shown.

examples/black_box_random_geometries/von_mises_fisher_example/train.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,4 +103,4 @@ def run(
103103
print(model)
104104

105105
# Trains
106-
run(model, train_dataset, test_dataset, name="vmf_motion")
106+
run(model, train_dataset, test_dataset, name="motion")

examples/black_box_random_geometries/von_mises_fisher_example/vae_motion.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ def forward(self, x: torch.Tensor):
7373
return q_z_given_x, p_x_given_z
7474

7575
def elbo_loss(self, x: torch.Tensor, q_z_given_x: Normal, p_x_given_z: VonMisesFisher):
76-
rec_loss = p_x_given_z.log_prob(x).sum(dim=1)
76+
rec_loss = -p_x_given_z.log_prob(x).sum(dim=1)
7777
kl = kl_divergence(q_z_given_x, self.p_z).sum(dim=1)
7878

7979
return (rec_loss + kl).mean()

0 commit comments

Comments
 (0)