快捷方式

TrainerHookBase

class torchrl.trainers.TrainerHookBase[source]

An abstract hooking class for torchrl Trainer class.

abstract register(trainer: Trainer, name: str)[source]

Registers the hook in the trainer at a default location.

参数:
  • trainer (Trainer) – the trainer where the hook must be registered.

  • name (str) – the name of the hook.

注意

To register the hook at another location than the default, use register_op().

文档

访问全面的 PyTorch 开发者文档

查看文档

教程

为初学者和高级开发者提供深入的教程

查看教程

资源

查找开发资源并让您的问题得到解答

查看资源