class_docstr: Parent class for entity linking encoder training and index
  datasets
  
  Args:
      tokenizer (obj): huggingface tokenizer,
      data_file (str): path to tab separated column file where data 
          pairs apear in the format 
          concept_ID  concept_synonym1        concept_synonym2
  
      newline_idx_file (str): path to pickle file containing location
          of data_file newline characters
      max_seq_length (int): maximum length of a concept in tokens
      is_index_data (bool): Whether dataset will be used for building
                          a nearest neighbors index
class_docstr_tok: ["Parent","class","for","entity","linking","encoder","training","and","index","datasets","Args",":","tokenizer","(","obj",")",":","huggingface","tokenizer",",","data_file","(","str",")",":","path","to","tab","separated","column","file","where","data","pairs","apear","in","the","format","concept_ID","concept_synonym1","concept_synonym2","newline_idx_file","(","str",")",":","path","to","pickle","file","containing","location","of","data_file","newline","characters","max_seq_length","(","int",")",":","maximum","length","of","a","concept","in","tokens","is_index_data","(","bool",")",":","Whether","dataset","will","be","used","for","building","a","nearest","neighbors","index"]
code: def __len__(self):
      return self.num_lines
  
file_path: NeMo/nemo/collections/nlp/data/entity_linking/entity_linking_dataset.py
imports: import array
  import pickle
  from typing import Optional
  import torch
  from nemo.collections.nlp.data.data_utils.data_preprocessing import find_newlines, load_data_indices
  from nemo.core.classes import Dataset
  from nemo.utils import logging
label_desc: Use image node_id 2 for calling the EntityLinkingDataset obj's underlying member method code with example usage: obj.__len__() and returns: self