parameters: (input: Tensor, inplace: bool = False)
return_statement: return torch._C._nn.hardsigmoid(input)
docstring: r"""Applies the element-wise function
  
      .. math::
          \text{Hardsigmoid}(x) = \begin{cases}
              0 & \text{if~} x \le -3, \\
              1 & \text{if~} x \ge +3, \\
              x / 6 + 1 / 2 & \text{otherwise}
          \end{cases}
  
      Args:
          inplace: If set to ``True``, will do this operation in-place. Default: ``False``
  
      See :class:`~torch.nn.Hardsigmoid` for more details.
docstring_summary: r"""Applies the element-wise function
docstring_tokens: r Applies the element - wise function
function: def hardsigmoid(input: Tensor, inplace: bool = False) -> Tensor:
      r"""Applies the element-wise function
  
      .. math::
          \text{Hardsigmoid}(x) = \begin{cases}
              0 & \text{if~} x \le -3, \\
              1 & \text{if~} x \ge +3, \\
              x / 6 + 1 / 2 & \text{otherwise}
          \end{cases}
  
      Args:
          inplace: If set to ``True``, will do this operation in-place. Default: ``False``
  
      See :class:`~torch.nn.Hardsigmoid` for more details.
      """
      if has_torch_function_unary(input):
          return handle_torch_function(hardsigmoid, (input,), input, inplace=inplace)
      if inplace:
          return torch._C._nn.hardsigmoid_(input)
      return torch._C._nn.hardsigmoid(input)
function_tokens: def hardsigmoid ( input : Tensor , inplace : bool = False ) -> Tensor : if has_torch_function_unary ( input ) : return handle_torch_function ( hardsigmoid , ( input , ) , input , inplace = inplace ) if inplace : return torch . _C . _nn . hardsigmoid_ ( input ) return torch . _C . _nn . hardsigmoid ( input )