code: def logical_not(x: Array, /) -> Array:
      """
      Array API compatible wrapper for :py:func:`np.logical_not <numpy.logical_not>`.
  
      See its docstring for more information.
      """
      if x.dtype not in _boolean_dtypes:
          raise TypeError(
              "Only boolean dtypes are allowed in logical_not"
          )
      return Array._new(np.logical_not(x._array))
  
imports: from __future__ import annotations
  from ._dtypes import _boolean_dtypes, _floating_dtypes, _integer_dtypes, _integer_or_boolean_dtypes, _numeric_dtypes, _result_type
  from ._array_object import Array
  import cupy
label_desc: Use image node_id 38 for calling a global function with example usage: logical_not() and returns: Array