Beispiel #1
0
def add_target_callback(config: TrainerConfigDict):
    """Add the update target and kl hook.

    This hook is called explicitly after each learner step in the execution
    setup for IMPALA.

    Args:
        config (TrainerConfigDict): The APPO config dict.
    """
    config["after_train_step"] = UpdateTargetAndKL
    validate_config(config)
Beispiel #2
0
def add_target_callback(config):
    """Add the update target and kl hook.

    This hook is called explicitly after each learner step in the execution
    setup for IMPALA.
    """

    config["after_train_step"] = UpdateTargetAndKL
    return validate_config(config)