code: def is_named_tuple(cls):
      """Return True if cls is a namedtuple and False otherwise."""
      b = cls.__bases__
      if len(b) != 1 or b[0] != tuple:
          return False
      f = getattr(cls, "_fields", None)
      if not isinstance(f, tuple):
          return False
      return all(type(n) == str for n in f)
  
imports: import collections
  import io
  import logging
  import re
  import string
  import sys
  import weakref
  from dataclasses import make_dataclass
  import numpy
  import pytest
  from numpy import log
  import ray
  import ray.cluster_utils
label_desc: Use image node_id 1 for calling a global function with example usage: is_named_tuple(cls) and returns: all, False, False