nfp.models.losses

Keras loss functions will choke on NaN inputs, which we’ll often have for unspecified inputs. These are just a couple simple loss functions that mask NaN values in both the test and predicted tensors when computing the cost.

Functions

masked_log_cosh

masked_mean_absolute_error

masked_mean_squared_error