code: def get_all_classes(c):
      """Recursive function to generate a flat list of all child classes of ``c``.
      (first called with ``Operator``)."""
      if c.__module__[:10] != "pennylane.":
          return []
      subs = c.__subclasses__()
      classes = [] if c in _ABSTRACT_OR_META_TYPES else [c]
      for sub in subs:
          classes.extend(get_all_classes(sub))
      return classes
  
file_path: pennylane/tests/ops/functions/conftest.py
imports: from inspect import getmembers, isclass
  import pytest
  import numpy
  import pennylane
  from pennylane.operation import Operator, Operation, Observable, Tensor, Channel
  from pennylane.operation import DiagGatesUndefinedError, MatrixUndefinedError
  from pennylane.ops.op_math.adjoint import Adjoint, AdjointObs, AdjointOperation, AdjointOpObs
  from pennylane.ops.op_math.pow import PowObs, PowOperation, PowOpObs
label_desc: Use image node_id 1 for calling a global function with example usage: get_all_classes(c) and returns: classes, list