code: def _has_external_source(pipeline):
      if not pipeline._py_graph_built:
          pipeline._build_graph()
      for op in pipeline._ops:
          if _is_external_source(op):
              return True
      return False
  
imports: from nvidia.dali import backend
  from nvidia.dali import tensors
  from nvidia.dali import types
  from nvidia.dali._multiproc.messages import TaskArgs, SampleRange
  import nvidia.dali.types
  from nvidia.dali._utils.external_source_impl import get_callback_from_source, accepted_arg_count, SourceKind
label_desc: Use image node_id 6 for calling a global function with example usage: _has_external_source(pipeline) and returns: False, True