code: def make_dict2dict(old_dict, new_dict):
      dict2dict_map = {}
      for sym in old_dict.symbols:
          dict2dict_map[old_dict.index(sym)] = new_dict.index(sym)
      return dict2dict_map
  
file_path: fairseq/examples/fast_noisy_channel/noisy_channel_sequence_generator.py
imports: from typing import Dict, List, Optional
  import math
  import numpy
  import torch
  import torch.nn.functional
  from torch import Tensor
  from .noisy_channel_beam_search import NoisyChannelBeamSearch
  from fairseq.sequence_generator import EnsembleModel
label_desc: Use image node_id 2 for calling a global function with example usage: make_dict2dict(old_dict, new_dict) and returns: dict2dict_map