1 def _file_to_word_ids(filename, word_to_id):
2   data = _read_words(filename)
3   return [word_to_id[word] for word in data if word in word_to_id]

Figure 1: Flow chart of _file_to_word_ids.py file

results matching ""

    No results matching ""