RolloutWorker.get_policies_to_train(batch: SampleBatch | MultiAgentBatch | None = None) Set[str][source]#

Returns all policies-to-train, given an optional batch.

Loops through all policies currently in self.policy_map and checks the return value of self.is_policy_to_train(pid, batch).


batch – An optional SampleBatchType for the self.is_policy_to_train(pid, [batch]?) check.


The set of currently trainable policy IDs, given the optional batch.

PublicAPI (alpha): This API is in alpha and may change before becoming stable.