快捷方式

torch.nn.functional.softplus

torch.nn.functional.softplus(input, beta=1, threshold=20) Tensor

逐元素應用函式 Softplus(x)=1βlog(1+exp(βx))\text{Softplus}(x) = \frac{1}{\beta} * \log(1 + \exp(\beta * x))

為了數值穩定性,當 input×β>thresholdinput \times \beta > threshold 時,實現會退化為線性函式。

更多詳情請參見 Softplus

文件

訪問 PyTorch 全面的開發者文件

檢視文件

教程

獲取針對初學者和高階開發者的深度教程

檢視教程

資源

查詢開發資源並獲得問題解答

檢視資源