def value_loss(self, model, observations, discounted_rewards):
        """ Loss of value estimator """
        value_outputs = model.value(observations)
        value_loss = 0.5 * F.mse_loss(value_outputs, discounted_rewards)
        return value_loss
Loss of value estimator