code: def any_sparse(classes):
      """Checks for sparse tensor.
  
      Args:
        classes: a structure of objects that identify the dataset item classes
  
      Returns:
        `True` if `classes` contains a sparse tensor type and `False` otherwise.
      """
      return any(
          c is sparse_tensor.SparseTensor for c in nest.flatten(classes)
      )
  
file_path: tensorflow/tensorflow/python/data/util/sparse.py
imports: from tensorflow.python.data.util import nest
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import sparse_tensor
  from tensorflow.python.framework import tensor
  from tensorflow.python.framework import tensor_shape
  from tensorflow.python.ops import sparse_ops
label_desc: Use image node_id 1 for calling a global function with example usage: any_sparse(classes) and returns: any