code: def build_tokenizer(vocab_file, tokenizer_type, vocab_extra_ids=0):
      """Initialize tokenizer."""
      if (
          not gpc.is_initialized(ParallelMode.GLOBAL)
          or gpc.get_global_rank() == 0
      ):
          print(
              "> building {} tokenizer ...".format(tokenizer_type),
              flush=True,
          )
  
      # Select and instantiate the tokenizer.
      if tokenizer_type == "BertWordPieceLowerCase":
          tokenizer = _BertWordPieceTokenizer(
              vocab_file=vocab_file,
              lower_case=True,
              vocab_extra_ids=vocab_extra_ids,
          )
      elif tokenizer_type == "BertWordPieceCase":
          tokenizer = _BertWordPieceTokenizer(
              vocab_file=vocab_file,
              lower_case=False,
              vocab_extra_ids=vocab_extra_ids,
          )
      else:
          raise NotImplementedError(
              "{} tokenizer is not "
              "implemented.".format(tokenizer_type)
          )
  
      # Add vocab size.
      padded_vocab_size = _vocab_size_with_padding(tokenizer.vocab_size)
  
      return tokenizer, padded_vocab_size
  
imports: from abc import ABC, abstractmethod
  from colossalai.legacy.context import ParallelMode
  from colossalai.legacy.core import global_context
  from .bert_tokenization import FullTokenizer
label_desc: Use image node_id 1 for calling a global function with example usage: build_tokenizer(vocab_file, tokenizer_type, vocab_extra_ids) and returns: tokenizer,  padded_vocab_size