code: def do(
      fp=None,
      directory=None,
      to="html",
      execute=True,
      timeout=1000,
      kernel_name="",
      parallel=False,
      report_errors=True,
      error_fail=False,
      skip_existing=False,
      execute_only=False,
      skip_specific=(),
  ):
      if fp is None:
          nbs = find_notebooks(directory)
      else:
          nbs = [fp]
  
      nbs = list(nbs)
      skip = set()
      for nb in nbs:
          for skip_nb in skip_specific:
              if skip_nb in nb:
                  skip.add(nb)
      nbs = [nb for nb in nbs if nb not in skip]
  
      if kernel_name is None:
          kernel_name = find_kernel_name()
  
      func = partial(
          do_one,
          to=to,
          execute=execute,
          timeout=timeout,
          kernel_name=kernel_name,
          report_error=report_errors,
          error_fail=error_fail,
          skip_existing=skip_existing,
          execute_only=execute_only,
      )
  
      if parallel and has_futures:
          with futures.ProcessPoolExecutor() as pool:
              for dst in pool.map(func, nbs):
                  print("Finished %s" % dst)
      else:
          for nb in nbs:
              func(nb)
              print("Finished %s" % nb)
  
      skip_func = partial(
          do_one,
          to=to,
          execute=False,
          timeout=timeout,
          kernel_name=kernel_name,
          report_error=report_errors,
          error_fail=error_fail,
          skip_existing=skip_existing,
          execute_only=execute_only,
      )
      for nb in skip:
          skip_func(nb)
          print("Finished (without execution) %s" % nb)
  
file_path: statsmodels/tools/nbgenerate.py
imports: import argparse
  import asyncio
  from functools import partial
  import hashlib
  import json
  import os
  import shutil
  import sys
  from colorama import Fore, init
  from nbconvert import HTMLExporter, RSTExporter
  from nbconvert.preprocessors import ExecutePreprocessor
  import nbformat
label_desc: Use image node_id 5 for calling a global function with example usage: do(fp, directory, to, execute, timeout, kernel_name, parallel, report_errors, error_fail, skip_existing, execute_only, skip_specific) without return types