code: def convert_state_dict(orig_state_dict, model):
      # rename keys
      for key in orig_state_dict.copy().keys():
          val = orig_state_dict.pop(key)
          orig_state_dict[rename_key(key)] = val
  
      # remove ignore keys
      remove_ignore_keys_(orig_state_dict)
  
      return orig_state_dict
  
file_path: transformers/src/transformers/models/bros/convert_bros_to_pytorch.py
imports: import argparse
  import bros
  import torch
  from transformers import BrosConfig, BrosModel, BrosProcessor
  from transformers.utils import logging
label_desc: Use image node_id 4 for calling a global function with example usage: convert_state_dict(orig_state_dict, model) and returns: orig_state_dict