code: def _ensure_directory(path):
      """Ensure that the parent directory of `path` exists"""
      dirname = os.path.dirname(path)
      if not os.path.isdir(dirname):
          os.makedirs(dirname)
  
imports: import os
  import sys
  import stat
  import fnmatch
  import collections
  import errno
label_desc: Use image node_id 35 for calling a global function with example usage: _ensure_directory(path) without return types