code: def load_model_card(path: Union[Path, str]) -> Optional[ModelCard]:
      """Loads a serialized model card from a file.
  
      Args:
        path: The path to the model card file. Supported formats are '.json' and
          '.proto'.
  
      Raises:
        ValueError: If the file suffix is not a supported save format.
        FileNotFoundError: If the file does not exist.
      """
      suffix = io_utils.suffix(path)
      _ensure_is_supported_save_format(suffix)
  
      if suffix == ".proto":
          model_card_proto = io_utils.parse_proto_file(
              path, model_card_pb2.ModelCard()
          )
          return ModelCard.from_proto(model_card_proto)
      elif suffix == ".json":
          model_card_json = json_lib.loads(io_utils.read_file(path))
          return ModelCard.from_json(model_card_json)
  
imports: import dataclasses
  import json
  import os
  from pathlib import Path
  from typing import Any, Dict, List, Optional, Union
  from model_card_toolkit.base_model_card_field import BaseModelCardField
  from model_card_toolkit.proto import model_card_pb2
  from model_card_toolkit.utils import io_utils, json_utils, template_utils
label_desc: Use image node_id 2 for calling a global function with example usage: load_model_card(path) and returns: ModelCard, ModelCard