kernel-elastic-autoencoder 3.3.1__tar.gz → 3.3.2__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: kernel_elastic_autoencoder
3
- Version: 3.3.1
3
+ Version: 3.3.2
4
4
  Summary: Implementation of Kernel-Elastic Autoencoder for Molecular Design (https://doi.org/10.1093/pnasnexus/pgae168)
5
5
  License: MIT
6
6
  Author: Felix Rotter-McCartney
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "kernel_elastic_autoencoder"
3
- version = "3.3.1"
3
+ version = "3.3.2"
4
4
  description = "Implementation of Kernel-Elastic Autoencoder for Molecular Design (https://doi.org/10.1093/pnasnexus/pgae168)"
5
5
  authors = [
6
6
  { name = "Felix Rotter-McCartney", email = "felix.rotter@mail.utoronto.ca" }
@@ -136,7 +136,7 @@ class Trainer:
136
136
  )
137
137
  accelerator.backward(loss)
138
138
  optimizer.step()
139
- torch.cat([train_loss, loss.detach()], dim=0)
139
+ torch.cat([train_loss, loss.detach().unsqueeze(-1)], dim=0)
140
140
  accelerator.print(f"Avg. train loss: {train_loss.mean().item()}")
141
141
 
142
142
  model.eval()
@@ -154,7 +154,7 @@ class Trainer:
154
154
  loss = loss_fn(
155
155
  prediction, prediction_noise, input_ids[:, 1:], latents_noise
156
156
  )
157
- torch.cat([test_loss, loss.detach()], dim=0)
157
+ torch.cat([test_loss, loss.detach().unsqueeze(-1)], dim=0)
158
158
  accelerator.print(f"Avg. test loss: {test_loss.mean().item()}")
159
159
 
160
160
  scheduler.step()