code: def test_einsum(
      *,
      eq_n_op_n_shp,
      dtype,
      test_flags,
      backend_fw,
      fn_name,
      on_device,
  ):
      eq, operands, dtypes = eq_n_op_n_shp
      kw = {}
      # x_dtype = np.dtype(dtype[0])
      for i, x_ in enumerate(operands):
          dtype = dtypes[i][0]
          kw[f"x{i}"] = np.array(x_).astype(dtype)
      # len(operands) + 1 because of the equation
      test_flags.num_positional_args = len(operands) + 1
      helpers.test_function(
          input_dtypes=dtypes,
          test_flags=test_flags,
          backend_to_test=backend_fw,
          fn_name=fn_name,
          on_device=on_device,
          equation=eq,
          **kw,
          rtol_=1e-2,
          atol_=1e-2,
      )
  
file_path: ivy/ivy_tests/test_ivy/test_functional/test_core/test_statistical.py
imports: import numpy
  from hypothesis import strategies, assume
  import ivy_tests.test_ivy.helpers
  from ivy_tests.test_ivy.helpers import handle_test
label_desc: Use image node_id 5 for calling a global function with example usage: test_einsum() without return types