code: def get_candidate_pool_tensor_helper(
      entity_desc_list,
      tokenizer,
      max_seq_length,
      logger,
      is_zeshel,
  ):
      if is_zeshel:
          return get_candidate_pool_tensor_zeshel(
              entity_desc_list,
              tokenizer,
              max_seq_length,
              logger,
          )
      else:
          return get_candidate_pool_tensor(
              entity_desc_list,
              tokenizer,
              max_seq_length,
              logger,
          )
  
imports: import argparse
  import json
  import logging
  import os
  import torch
  from tqdm import tqdm
  from torch.utils.data import DataLoader, RandomSampler, SequentialSampler, TensorDataset
  from pytorch_transformers.tokenization_bert import BertTokenizer
  from blink.biencoder.biencoder import BiEncoderRanker
  import blink.biencoder.data_process
  import blink.biencoder.nn_prediction
  import blink.candidate_ranking.utils
  from blink.biencoder.zeshel_utils import WORLDS, load_entity_dict_zeshel, Stats
  from blink.common.params import BlinkParser
label_desc: Use image node_id 3 for calling a global function with example usage: get_candidate_pool_tensor_helper(entity_desc_list, tokenizer, max_seq_length, logger, is_zeshel) and returns: get_candidate_pool_tensor_zeshel, get_candidate_pool_tensor