NoisyLazyLinear¶
- class torchrl.modules.NoisyLazyLinear(out_features: int, bias: bool = True, device: Optional[Union[device, str, int]] = None, dtype: Optional[dtype] = None, std_init: float = 0.1)[來源]¶
Noisy Lazy 線性層。
此類別使 Noisy 線性層變得 lazy,因為不需要在初始化時傳遞 in_feature 引數 (但在第一次呼叫該層後會推斷出來)。
有關 noisy 層的更多資訊,請參閱 NoisyLinear 類別。
- 參數:
out_features (int) – out features 維度
bias (bool, optional) – 如果
True
,則將偏差項新增到矩陣乘法:Ax + b。預設為True
。device (DEVICE_TYPING, optional) – 層的裝置。預設為
"cpu"
。dtype (torch.dtype, optional) – 參數的 dtype。預設為預設的 PyTorch dtype。
std_init (scalar) – 最佳化之前高斯標準差的初始值。預設為 0.1