code: def grad(self):
          
          from . import _ndarray_cls
          hdl = NDArrayHandle()
          check_call(_LIB.MXNDArrayGetGrad(self.handle, ctypes.byref(hdl)))
          if hdl.value is None:
              return None
          return _ndarray_cls(hdl)
docs: Returns gradient buffer attached to this NDArray.