def is_device_array(self, obj): if dgpu_present: return devicearray.is_hsa_ndarray(obj) else: return True
def is_device_array(self, obj): if dgpu_present: return devicearray.is_hsa_ndarray(obj) else: return isinstance(obj, np.ndarray)