code: def hardsigmoid(x, slope=0.1666667, offset=0.5, name=None):
      ret = ivy.minimum(
          ivy.maximum(ivy.add(ivy.multiply(x, slope), offset), 0), 1
      )
      return ret
  
imports: import ivy
  from ivy.func_wrapper import with_supported_dtypes
  from ivy.functional.frontends.paddle.func_wrapper import to_ivy_arrays_and_back
  from ivy.functional.frontends.paddle.tensor.math import tanh
label_desc: Use image node_id 7 for calling a global function with example usage: hardsigmoid(x, slope, offset, name) and returns: ret