code: def test_ndarray_negate():
      npy = np.random.uniform(-10, 10, (2, 3, 4))
      arr = mx.nd.array(npy)
      assert reldiff(npy, arr.asnumpy()) < 1e-6
      assert reldiff(-npy, (-arr).asnumpy()) < 1e-6
  
      # a final check to make sure the negation (-) is not implemented
      # as inplace operation, so the contents of arr does not change after
      # we compute (-arr)
      assert reldiff(npy, arr.asnumpy()) < 1e-6
  
imports: import os
  import mxnet
  import numpy
  import pickle
label_desc: Use image node_id 7 for calling a global function with example usage: test_ndarray_negate() without return types