code: def __init__(
      self,
      basename="",
      parentdir=None,
      ext=".whoosh",
      suppress=frozenset(),
      keepdir=False,
  ):
      self.basename = basename or random_name(8)
      self.parentdir = parentdir
  
      dirname = parentdir or tempfile.mkdtemp(ext, self.basename)
      self.dir = os.path.abspath(dirname)
      self.suppress = suppress
      self.keepdir = keepdir
  
imports: import os.path
  import shutil
  import sys
  import tempfile
  from contextlib import contextmanager
  from whoosh.filedb.filestore import FileStorage
  from whoosh.util import now, random_name
label_desc: Use image node_id 1 to create a new TempDir object from inherited base classes: object with example: obj = TempDir(basename, parentdir, ext, suppress, keepdir)