code: def get_word_id_dict(word_num_dict, word_id_dict, min_count):
      z = [k for k in sorted(word_num_dict.keys())]
      for word in z:
          count = word_num_dict[word]
          if count >= min_count:
              index = len(word_id_dict)
              if word not in word_id_dict:
                  word_id_dict[word] = index
      return word_id_dict
  
imports: import logging
  import os
  import pickle
  from collections import Counter
  import numpy
  import torch
  from torch.utils import data
label_desc: Use image node_id 7 for calling a global function with example usage: get_word_id_dict(word_num_dict, word_id_dict, min_count) and returns: word_id_dict