本文簡要介紹python語言中 torch.nn.LeakyReLU 的用法。
- 用法:- class torch.nn.LeakyReLU(negative_slope=0.01, inplace=False)
- negative_slope-控製負斜率的角度。默認值:1e-2 
- inplace-可以選擇就地執行操作。默認值: - False
 
- 應用逐元素函數: - 或者 - 形狀:
- 輸入: 其中 - *表示任意數量的附加維度
- 輸出:,與輸入的形狀相同 
 
   - 例子:- >>> m = nn.LeakyReLU(0.1) >>> input = torch.randn(2) >>> output = m(input)
參數:
相關用法
- Python PyTorch LazyModuleMixin用法及代碼示例
- Python PyTorch LinearLR用法及代碼示例
- Python PyTorch LKJCholesky用法及代碼示例
- Python PyTorch L1Loss用法及代碼示例
- Python PyTorch LPPool2d用法及代碼示例
- Python PyTorch LogSigmoid用法及代碼示例
- Python PyTorch LowRankMixtureCrossNet用法及代碼示例
- Python PyTorch LayerNorm用法及代碼示例
- Python PyTorch LineReader用法及代碼示例
- Python PyTorch LogNormal用法及代碼示例
- Python PyTorch LambdaLR用法及代碼示例
- Python PyTorch LocalResponseNorm用法及代碼示例
- Python PyTorch LSTM用法及代碼示例
- Python PyTorch LowRankMultivariateNormal用法及代碼示例
- Python PyTorch Linear用法及代碼示例
- Python torchrec.modules.crossnet.LowRankCrossNet用法及代碼示例
- Python PyTorch LogSoftmax用法及代碼示例
- Python PyTorch LSTMCell用法及代碼示例
- Python PyTorch LocalElasticAgent用法及代碼示例
- Python PyTorch LPPool1d用法及代碼示例
- Python PyTorch Laplace用法及代碼示例
- Python PyTorch LazyModuleExtensionMixin.apply用法及代碼示例
- Python PyTorch LinearReLU用法及代碼示例
- Python PyTorch frexp用法及代碼示例
- Python PyTorch jvp用法及代碼示例
注:本文由純淨天空篩選整理自pytorch.org大神的英文原創作品 torch.nn.LeakyReLU。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。
