code: def put_local_dir_tree_to_remote(
      local_dir, remote_dir, over_write=False
  ):
      if not exists(remote_dir):
          mkdirs(remote_dir)
      for dirpath, dirnames, filenames in os.walk(local_dir):
          for d in dirnames:
              remote_subdir = os.path.join(
                  remote_dir, dirpath[len(local_dir) + 1 :], d
              )
              if not exists(remote_subdir):
                  mkdirs(remote_subdir)
          for f in filenames:
              remote_file = os.path.join(
                  remote_dir, dirpath[len(local_dir) + 1 :], f
              )
              put_local_file_to_remote(
                  os.path.join(dirpath, f),
                  remote_file,
                  over_write=over_write,
              )
  
imports: import functools
  import glob
  import os
  import subprocess
  import tempfile
  import uuid
  from urllib.parse import urlparse
  import numpy
  from bigdl.dllib.utils.common import Sample, JTensor, JavaCreator, _get_gateway, _py2java, _java2py
  from bigdl.dllib.utils.log4Error import *
label_desc: Use image node_id 20 for calling a global function with example usage: put_local_dir_tree_to_remote(local_dir, remote_dir, over_write) without return types