code: def moco_convert(src, dst):
      """Convert keys in pycls pretrained moco models to mmdet style."""
      # load caffe model
      moco_model = torch.load(src)
      blobs = moco_model["state_dict"]
      # convert to pytorch style
      state_dict = OrderedDict()
      for k, v in blobs.items():
          if not k.startswith("module.encoder_q."):
              continue
          old_k = k
          k = k.replace("module.encoder_q.", "")
          state_dict[k] = v
          print(old_k, "->", k)
      # save checkpoint
      checkpoint = dict()
      checkpoint["state_dict"] = state_dict
      torch.save(checkpoint, dst)
  
imports: import argparse
  from collections import OrderedDict
  import torch
label_desc: Use image node_id 1 for calling a global function with example usage: moco_convert(src, dst) without return types