code: def kaiser(M, beta):
      if M <= 1:
          return ivy.ones([M], dtype=ivy.float64)
      n = ivy.arange(M)
      alpha = 0.5 * (M - 1)
      ret = ivy.i0(
          beta * ivy.sqrt(1 - ((n - alpha) / alpha) ** 2)
      ) / ivy.i0(beta)
      return ret
  
imports: import ivy
  from ivy.functional.frontends.jax.func_wrapper import to_ivy_arrays_and_back, handle_jax_dtype
  from ivy.functional.frontends.jax.numpy import promote_types_of_jax_inputs
label_desc: Use image node_id 25 for calling a global function with example usage: kaiser(M, beta) and returns: ret, ivy