• 文档 >
  • 量化 >
  • 量化 API 参考 >
  • leaky_relu
快捷键

leaky_relu

class torch.ao.nn.quantized.functional.leaky_relu(input, negative_slope=0.01, inplace=False, scale=None, zero_point=None)[source][source]

量化版本的 leaky_relu(input, negative_slope=0.01, inplace=False, scale, zero_point) -> Tensor

元素级应用, LeakyReLU(x)=max(0,x)+negative_slopemin(0,x)\text{LeakyReLU}(x) = \max(0, x) + \text{negative\_slope} * \min(0, x)

参数:
  • 输入(张量)- 量化输入

  • 负斜率(浮点数)- 负输入的斜率

  • inplace(布尔值)- 输入张量的就地修改

  • scale(可选[浮点数])- 输出张量的缩放和零点

  • 零点(可选[int])- 输出张量的缩放比例和零点。

更多详情请见 LeakyReLU


© 版权所有 PyTorch 贡献者。

使用 Sphinx 构建,主题由 Read the Docs 提供。

文档

查看 PyTorch 的全面开发者文档

查看文档

教程

深入了解初学者和高级开发者的教程

查看教程

资源

查找开发资源并获得您的疑问解答

查看资源