diff options
author | Jordan Gong <jordan.gong@protonmail.com> | 2021-03-27 21:27:12 +0800 |
---|---|---|
committer | Jordan Gong <jordan.gong@protonmail.com> | 2021-03-27 21:27:12 +0800 |
commit | 99d1b18ac380bcf7d7579d80e09c9ddaecde44b3 (patch) | |
tree | ab8a74b1f3c314441ae75a1abdac85605c9633d8 /models | |
parent | 5a063855dbecb8f1a86ad25d9e61a9c8b63312b3 (diff) |
Normalize triplet losses
Diffstat (limited to 'models')
-rw-r--r-- | models/model.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/models/model.py b/models/model.py index ceadb92..cc5887e 100644 --- a/models/model.py +++ b/models/model.py @@ -344,8 +344,8 @@ class Model: ) losses = torch.stack(( *ae_losses, - hpm_result.pop('loss').mean(), - pn_result.pop('loss').mean() + torch.log(hpm_result.pop('loss').mean() + 1), + torch.log(pn_result.pop('loss').mean() + 1) )) return losses, hpm_result, pn_result |