code: def _ensure_dir_exists(path):
      try:
          os.makedirs(path)
      except OSError:
          if not os.path.isdir(path):
              raise
  
imports: import hashlib
  import logging
  import numpy
  import os
  import pandas
  import tarfile
  import tempfile
  import six
  import shutil
  from .core import PATH_TYPES, fspath
label_desc: Use image node_id 3 for calling a global function with example usage: _ensure_dir_exists(path) without return types