code: def is_named_tuple(obj):
      """
      Check if the object is a named tuple.
  
      Parameters
      ----------
      obj : The object to check
  
      Returns
      -------
      is_named_tuple : bool
          Whether `obj` is a named tuple.
  
      Examples
      --------
      >>> Point = namedtuple("Point", ["x", "y"])
      >>> p = Point(1, 2)
      >>>
      >>> is_named_tuple(p)
      True
      >>> is_named_tuple((1, 2))
      False
      """
  
      return isinstance(obj, tuple) and hasattr(obj, "_fields")
  
file_path: catboost/contrib/python/pandas/py2/pandas/core/dtypes/inference.py
imports: from numbers import Number
  import re
  import numpy
  from pandas._libs import lib
  from pandas.compat import PY2, Set, re_type, string_and_binary_types, string_types, text_type
  from pandas import compat
label_desc: Use image node_id 12 for calling a global function with example usage: is_named_tuple(obj) and returns: unknown