code: def get_dict_from_cache(
      meta: Union[Path, str]
  ) -> Optional[Dict[str, str]]:
      meta = Path(meta)
      outpath = meta.parent.parent
      if not meta.exists():
          return None
  
      with meta.open("r", encoding="utf-8") as f:
          d = yaml.safe_load(f)
          assert isinstance(d, dict), type(d)
          yaml_files = d["yaml_files"]
          files = d["files"]
          assert isinstance(yaml_files, dict), type(yaml_files)
          assert isinstance(files, dict), type(files)
  
          retval = {}
          for key, value in list(yaml_files.items()) + list(
              files.items()
          ):
              if not (outpath / value).exists():
                  return None
              retval[key] = str(outpath / value)
          return retval
  
imports: import os
  import sys
  import tarfile
  import zipfile
  from datetime import datetime
  from io import BytesIO, TextIOWrapper
  from pathlib import Path
  from typing import Dict, Iterable, Optional, Union
  import yaml
label_desc: Use image node_id 2 for calling a global function with example usage: get_dict_from_cache(meta) and returns: None, retval, None