快捷方式

leaky_relu

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

量化版本的 leaky_relu。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)

参数
  • input (Tensor) – 量化输入

  • negative_slope (float) – 负输入的斜率

  • inplace (bool) – 就地修改输入张量

  • scale (Optional[float]) – 输出张量的尺度和零点。

  • zero_point (Optional[int]) – 输出张量的尺度和零点。

有关更多详细信息,请参见 LeakyReLU

文档

查阅 PyTorch 的全面开发者文档

查看文档

教程

获取针对初学者和高级开发者的深入教程

查看教程

资源

查找开发资源并获得问题解答

查看资源