code: def load_and_render_yaml_template(
      template_path: str, env: Optional[Dict] = None
  ) -> Optional[Dict]:
      if not template_path:
          return None
  
      if not os.path.isfile(template_path):
          raise ReleaseTestConfigError(
              f"Cannot load yaml template from {template_path}: Path not found."
          )
  
      with open(template_path, "rt") as f:
          content = f.read()
  
      return render_yaml_template(template=content, env=env)
  
file_path: ray/release/ray_release/template.py
imports: import copy
  import datetime
  import os
  from typing import Optional, Dict, TYPE_CHECKING
  import jinja2
  import yaml
  from ray_release.bazel import bazel_runfile
  from ray_release.config import get_test_cloud_id
  from ray_release.exception import ReleaseTestConfigError
label_desc: Use image node_id 5 for calling a global function with example usage: load_and_render_yaml_template(template_path, env) and returns: render_yaml_template, None