code: def diag(v, k=0):
      return ivy.diag(v, k=k)
  
file_path: ivy/ivy/functional/frontends/numpy/indexing_routines/indexing_like_operations.py
imports: import ivy
  from ivy.functional.frontends.numpy.func_wrapper import to_ivy_arrays_and_back, inputs_to_ivy_arrays, handle_numpy_out
label_desc: Use image node_id 2 for calling a global function with example usage: diag(v, k) and returns: ivy