code: def _format_state_key(model: torch.nn.Module, attr: str):
      if hasattr(model, "format_state_key"):
          formatted_attr = model.format_state_key(attr)
      else:
          formatted_attr = attr
  
      return formatted_attr
  
file_path: mmf/mmf/utils/checkpoint_updater.py
imports: import logging
  from typing import Any, Dict, Tuple
  import torch
  from mmf.common.registry import registry
label_desc: Use image node_id 4 for calling a global function with example usage: _format_state_key(model, attr) and returns: formatted_attr