ray.rllib.core.learner.learner.Learner.get_param_ref#

abstract Learner.get_param_ref(param: torch.Tensor | tf.Variable) Hashable[source]#

Returns a hashable reference to a trainable parameter.

This should be overridden in framework specific specialization. For example in torch it will return the parameter itself, while in tf it returns the .ref() of the variable. The purpose is to retrieve a unique reference to the parameters.

Parameters:

param – The parameter to get the reference to.

Returns:

A reference to the parameter.