code: def test_rocm_copy():
      def check_rocm(dtype, n):
          A = te.placeholder((n,), name="A", dtype=dtype)
          dev = tvm.rocm(0)
          a_np = np.random.uniform(size=(n,)).astype(A.dtype)
          a = tvm.nd.empty((n,), A.dtype, dev).copyfrom(a_np)
          b_np = a.numpy()
          tvm.testing.assert_allclose(a_np, b_np)
          tvm.testing.assert_allclose(a_np, a.numpy())
  
      for _ in range(100):
          dtype = np.random.choice(
              ["float32", "float16", "int8", "int32"]
          )
          logN = np.random.randint(1, 15)
          peturb = np.random.uniform(low=0.5, high=1.5)
          check_rocm(dtype, int(peturb * (2**logN)))
  
file_path: tvm/tests/python/codegen/test_target_codegen_rocm.py
imports: import tvm
  import tvm.testing
  from tvm import te
  import numpy
  import unittest
  from tvm.script import tir
label_desc: Use image node_id 4 for calling a global function with example usage: test_rocm_copy() without return types