code: def isreal(x):
      """Returns a bool array, where True if input element is real.
  
      If element has complex type with zero complex part, the return value
      for that element is True.
  
      Args:
          x (cupy.ndarray): Input array.
  
      Returns:
          cupy.ndarray: Boolean array of same shape as ``x``.
  
      .. seealso::
          :func:`iscomplex`, :func:`isrealobj`
  
      Examples
      --------
      >>> cupy.isreal(cp.array([1+1j, 1+0j, 4.5, 3, 2, 2j]))
      array([False,  True,  True,  True,  True, False])
  
      """
      if numpy.isscalar(x):
          return numpy.isreal(x)
      if not isinstance(x, cupy.ndarray):
          return cupy.asarray(numpy.isreal(x))
      if x.dtype.kind == "c":
          return x.imag == 0
      return cupy.ones(x.shape, bool)
  
imports: import numpy
  import cupy
label_desc: Use image node_id 4 for calling a global function with example usage: isreal(x) and returns: cupy, numpy, cupy, unknown