快捷方式

VIPRewardTransform

class torchrl.envs.transforms.VIPRewardTransform(*args, **kwargs)[原始檔]

一個基於嵌入相似性計算獎勵的 VIP Transform。

此類將更新獎勵計算

forward(tensordict)[原始檔]

讀取輸入的 tensordict,並對選定的鍵應用 Transform。

transform_input_spec(input_spec: TensorSpec) TensorSpec[原始檔]

轉換輸入 Spec,使結果 Spec 與 Transform 對映匹配。

引數:

input_spec (TensorSpec) – 應用 Transform 之前的 Spec

返回:

應用 Transform 之後預期的 Spec


© 版權所有 2022, Meta.

使用 Sphinx 構建,主題由 Read the Docs 提供。

文件

查閱全面的 PyTorch 開發者文件

檢視文件

教程

獲取面向初學者和高階開發者的深度教程

檢視教程

資源

查詢開發資源並解答您的疑問

檢視資源