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

TorchModelV2.value_function() numpy.array | jnp.ndarray | tf.Tensor | torch.Tensor#

Returns the value function output for the most recent forward pass.

Note that a forward call has to be performed first, before this methods can return anything and thus that calling this method does not cause an extra forward pass through the network.

Returns:

Value estimate tensor of shape [BATCH].