code: def file_exists(dir_path: Optional[str]) -> bool:
      return dir_path is not None and os.path.exists(dir_path)
  
imports: import os
  import datetime
  import importlib
  from accelerate.logging import get_logger
  from typing import Union, Optional
  import shutil
  import torch
  from accelerate.utils import set_seed
  from transformers import AutoTokenizer, BertTokenizer
  from .enum_type import PLM_MODELS, RNN_MODELS
label_desc: Use image node_id 4 for calling a global function with example usage: file_exists(dir_path) and returns: unknown