code: def assert_valid_pipeline(pipeline):
      """Quick check to ensure the pipeline is an mlens Pipeline"""
      cls = str(pipeline.__class__).split("'")[1].lower()
      if not cls.endswith("pipeline") and not cls.startswith("mlens"):
          raise ValueError(
              "Expect mlens Pipeline instance. Got %r" % pipeline
          )
  
imports: import warnings
  from .exceptions import NotFittedError, LayerSpecificationWarning, LayerSpecificationError, ParallelProcessingError, ParallelProcessingWarning
label_desc: Use image node_id 4 for calling a global function with example usage: assert_valid_pipeline(pipeline) without return types