code: def get_bigdl_packages():
      bigdl_python_home = os.path.abspath(__file__ + "/..")
      bigdl_packages = ["bigdl.share.serving"]
      source_dir = os.path.join(bigdl_python_home, "bigdl")
      for dirpath, dirs, files in os.walk(source_dir):
          package = dirpath.split(bigdl_python_home)[1].replace(
              "/", "."
          )
          if any(
              fnmatch.fnmatchcase(package, pat=pattern)
              for pattern in exclude_patterns
          ):
              print("excluding", package)
          else:
              bigdl_packages.append(package)
              print("including", package)
      return bigdl_packages
  
imports: import os
  from shutil import copytree, rmtree
  from setuptools import setup
  import fnmatch
label_desc: Use image node_id 1 for calling a global function with example usage: get_bigdl_packages() and returns: bigdl_packages