ray.rllib.models.torch.torch_modelv2.TorchModelV2.metrics#

TorchModelV2.metrics() Dict[str, numpy.array | jnp.ndarray | tf.Tensor | torch.Tensor]#

Override to return custom metrics from your model.

The stats will be reported as part of the learner stats, i.e., info.learner.[policy_id, e.g. “default_policy”].model.key1=metric1

Returns:

The custom metrics for this model.