code: def test_ewise(
      target, dev, topi_name, dtype, tolerance, ewise_ref_data
  ):
      target = tvm.target.Target(target)
      if target.kind.name == "vulkan" and topi_name in [
          "tan",
          "erf",
          "isnan",
          "isfinite",
          "isinf",
      ]:
          pytest.xfail(
              f"Vulkan runtime doesn't support {topi_name} yet"
          )
  
      topi_op = ewise_operations[topi_name]["topi"]
      skip_name_check = ewise_operations[topi_name].get(
          "skip_name_check", False
      )
  
      m = te.var("m")
      l = te.var("l")
      A = te.placeholder((m, l), dtype=dtype, name="A")
  
      B = topi_op(A)
      assert tuple(B.shape) == tuple(A.shape)
      if not skip_name_check:
          assert B.op.body[0].op.name == "tir." + topi_name
  
      a_np, b_np = ewise_ref_data
  
      with tvm.target.Target(target):
          s = tvm.topi.testing.get_injective_schedule(target)(B)
      foo = tvm.build(s, [A, B], target, name=topi_name)
      a = tvm.nd.array(a_np, dev)
      b = tvm.nd.array(np.zeros_like(b_np), dev)
      foo(a, b)
      tvm.testing.assert_allclose(
          b.numpy(), b_np, rtol=tolerance, atol=tolerance
      )
  
file_path: tvm/tests/python/topi/test_topi_math.py
imports: import sys
  import numpy
  import pytest
  import scipy
  from scipy import special
  import tvm
  import tvm.testing
  import tvm.topi.testing
  from tvm import te, topi
  from tvm.topi import utils
label_desc: Use image node_id 3 for calling a global function with example usage: test_ewise(target, dev, topi_name, dtype, tolerance, ewise_ref_data) without return types