ray.rllib.core.learner.learner_group.LearnerGroup.set_is_module_trainable#

LearnerGroup.set_is_module_trainable(is_module_trainable: Optional[Callable[[str, ray.rllib.policy.sample_batch.MultiAgentBatch], bool]] = None) None[source]#

Sets the function that determines whether a module is trainable.

Parameters

is_module_trainable – A function that takes in a module id and a batch and returns a boolean indicating whether the module should be trained on the batch.