Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions neural_lam/models/base_graph_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,9 @@ def predict_step(self, prev_state, prev_prev_state, forcing):
# NOTE: The predicted std. is not scaled in any way here
# linter for some reason does not think softplus is callable
# pylint: disable-next=not-callable
eps = 1e-6
pred_std = torch.nn.functional.softplus(pred_std_raw)
pred_std = torch.clamp(pred_std, min=eps)
else:
pred_delta_mean = net_output
pred_std = None
Expand Down