code: def _copy_tree(
      backend_reference_path: str, backend_generation_path: str
  ):
      for root, _, files in os.walk(backend_reference_path):
          # Skip pycache dirs
          if root.endswith("__pycache__"):
              continue
  
          relative_path = os.path.relpath(root, backend_reference_path)
          # Make backend dirs
          os.makedirs(
              os.path.join(backend_generation_path, relative_path),
              exist_ok=True,
          )
  
          for name in files:
              # Skip pycache modules
              if name.endswith("pyc"):
                  continue
  
              with open(os.path.join(root, name)) as ref_file:
                  # Read source file from reference backend
                  ref_str = ref_file.read()
  
              ref_tree = ast.parse(ref_str)
              try:
                  tree_to_write = _parse_module(ref_tree)
              except Exception as e:
                  print(
                      f"Failed to parse {os.path.join(root, name)}, {e}"
                  )
  
              # Create target backend
              with open(
                  os.path.join(
                      backend_generation_path, relative_path, name
                  ),
                  "w",
              ) as generated_file:
                  generated_file.write(
                      astunparse.unparse(tree_to_write)
                  )
  
imports: import astunparse
  import ast
  import json
  import sys
  import subprocess
  import os
  import logging
  from shared import BackendNativeObject
label_desc: Use image node_id 2 for calling a global function with example usage: _copy_tree(backend_reference_path, backend_generation_path) without return types