class_docstr: Constructs an EmbeddingTokenizer.
      
class_docstr_tok: ["Constructs","an","EmbeddingTokenizer","."]
docstr: Load the tokenizer from local path or remote.
docstr_tok: ["Load","the","tokenizer","from","local","path","or","remote","."]
code: def from_pretrained(cls, pretrained_model_name_or_path, **kwargs):
      """Load the tokenizer from local path or remote."""
      if (
          pretrained_model_name_or_path
          in EMBEDDING_VOCAB_FILES_MAP["vocab_file"]
      ):
          # Get the vocabulary from AWS S3 bucket or cache
          resolved_vocab_file = load_from_cache(
              pretrained_model_name_or_path,
              EMBEDDING_VOCAB_FILES_MAP["vocab_file"],
              **kwargs,
          )
      elif os.path.isdir(pretrained_model_name_or_path):
          # Get the vocabulary from local files
          logger.info(
              f"Model name '{pretrained_model_name_or_path}' not found in model shortcut name "
              f"list ({', '.join(EMBEDDING_VOCAB_FILES_MAP['vocab_file'].keys())}). "
              f"Assuming '{pretrained_model_name_or_path}' is a path to a directory containing tokenizer files."
          )
  
          temp = open(
              str(
                  Path(pretrained_model_name_or_path)
                  / "language_model_config.json"
              ),
              "r",
              encoding="utf-8",
          ).read()
          config_dict = json.loads(temp)
  
          resolved_vocab_file = str(
              Path(pretrained_model_name_or_path)
              / config_dict["vocab_filename"]
          )
      else:
          logger.error(
              f"Model name '{pretrained_model_name_or_path}' not found in model shortcut name "
              f"list ({', '.join(EMBEDDING_VOCAB_FILES_MAP['vocab_file'].keys())}) nor as local folder "
          )
          raise NotImplementedError
  
      tokenizer = cls(vocab_file=resolved_vocab_file, **kwargs)
      return tokenizer
  
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  import collections
  import json
  import logging
  import os
  import re
  from pathlib import Path
  import numpy
  from transformers import AlbertTokenizer, AlbertTokenizerFast, BertTokenizer, BertTokenizerFast, DistilBertTokenizer, DistilBertTokenizerFast, ElectraTokenizer, ElectraTokenizerFast, RobertaTokenizer, RobertaTokenizerFast, XLMRobertaTokenizer, XLMRobertaTokenizerFast, XLNetTokenizer, XLNetTokenizerFast, CamembertTokenizer, CamembertTokenizerFast, DPRContextEncoderTokenizer, DPRContextEncoderTokenizerFast, DPRQuestionEncoderTokenizer, DPRQuestionEncoderTokenizerFast, BigBirdTokenizer, BigBirdTokenizerFast
  from transformers.models.bert.tokenization_bert import load_vocab
  from transformers.tokenization_utils import PreTrainedTokenizer
  from transformers import AutoConfig
  from farm.data_handler.samples import SampleBasket
  from farm.modeling.wordembedding_utils import load_from_cache, EMBEDDING_VOCAB_FILES_MAP, run_split_on_punc
label_desc: Use image node_id 3 for calling the EmbeddingTokenizer obj's underlying member method code with example usage: obj.from_pretrained(cls, pretrained_model_name_or_path) and returns: tokenizer