class_docstr: Construct a "fast" MBART tokenizer for mBART-50 (backed by HuggingFace's *tokenizers* library). Based on
  [BPE](https://huggingface.co/docs/tokenizers/python/latest/components.html?highlight=BPE#models).
  
  This tokenizer inherits from [`PreTrainedTokenizerFast`] which contains most of the main methods. Users should
  refer to this superclass for more information regarding those methods.
  
  Args:
      vocab_file (`str`):
          Path to the vocabulary file.
      src_lang (`str`, *optional*):
          A string representing the source language.
      tgt_lang (`str`, *optional*):
          A string representing the target language.
      eos_token (`str`, *optional*, defaults to `"</s>"`):
          The end of sequence token.
      sep_token (`str`, *optional*, defaults to `"</s>"`):
          The separator token, which is used when building a sequence from multiple sequences, e.g. two sequences for
          sequence classification or for a text and a question for question answering. It is also used as the last
          token of a sequence built with special tokens.
      cls_token (`str`, *optional*, defaults to `"<s>"`):
          The classifier token which is used when doing sequence classification (classification of the whole sequence
          instead of per-token classification). It is the first token of the sequence when built with special tokens.
      unk_token (`str`, *optional*, defaults to `"<unk>"`):
          The unknown token. A token that is not in the vocabulary cannot be converted to an ID and is set to be this
          token instead.
      pad_token (`str`, *optional*, defaults to `"<pad>"`):
          The token used for padding, for example when batching sequences of different lengths.
      mask_token (`str`, *optional*, defaults to `"<mask>"`):
          The token used for masking values. This is the token used when training this model with masked language
          modeling. This is the token which the model will try to predict.
  
  Examples:
  
  ```python
  >>> from transformers import MBart50TokenizerFast
  
  >>> tokenizer = MBart50TokenizerFast.from_pretrained("facebook/mbart-large-50", src_lang="en_XX", tgt_lang="ro_RO")
  >>> src_text = " UN Chief Says There Is No Military Solution in Syria"
  >>> tgt_text = "Şeful ONU declară că nu există o soluţie militară în Siria"
  >>> model_inputs = tokenizer(src_text, text_target=tgt_text, return_tensors="pt")
  >>> # model(**model_inputs) should work
  ```
class_docstr_tok: ["Construct","a","``","fast","''","MBART","tokenizer","for","mBART-50","(","backed","by","HuggingFace","'s","*","tokenizers","*","library",")",".","Based","on","[","BPE","]","(","https",":","\/\/huggingface.co\/docs\/tokenizers\/python\/latest\/components.html","?","highlight=BPE","#","models",")",".","This","tokenizer","inherits","from","[","`","PreTrainedTokenizerFast","`","]","which","contains","most","of","the","main","methods",".","Users","should","refer","to","this","superclass","for","more","information","regarding","those","methods",".","Args",":","vocab_file","(","`","str","`",")",":","Path","to","the","vocabulary","file",".","src_lang","(","`","str","`",",","*","optional","*",")",":","A","string","representing","the","source","language",".","tgt_lang","(","`","str","`",",","*","optional","*",")",":","A","string","representing","the","target","language",".","eos_token","(","`","str","`",",","*","optional","*",",","defaults","to","`","``","<","\/s",">","''","`",")",":","The","end","of","sequence","token",".","sep_token","(","`","str","`",",","*","optional","*",",","defaults","to","`","``","<","\/s",">","''","`",")",":","The","separator","token",",","which","is","used","when","building","a","sequence","from","multiple","sequences",",","e.g",".","two","sequences","for","sequence","classification","or","for","a","text","and","a","question","for","question","answering",".","It","is","also","used","as","the","last","token","of","a","sequence","built","with","special","tokens",".","cls_token","(","`","str","`",",","*","optional","*",",","defaults","to","`","``","<","s",">","''","`",")",":","The","classifier","token","which","is","used","when","doing","sequence","classification","(","classification","of","the","whole","sequence","instead","of","per-token","classification",")",".","It","is","the","first","token","of","the","sequence","when","built","with","special","tokens",".","unk_token","(","`","str","`",",","*","optional","*",",","defaults","to","`","``","<","unk",">","''","`",")",":","The","unknown","token",".","A","token","that","is","not","in","the","vocabulary","can","not","be","converted","to","an","ID","and","is","set","to","be","this","token","instead",".","pad_token","(","`","str","`",",","*","optional","*",",","defaults","to","`","``","<","pad",">","''","`",")",":","The","token","used","for","padding",",","for","example","when","batching","sequences","of","different","lengths",".","mask_token","(","`","str","`",",","*","optional","*",",","defaults","to","`","``","<","mask",">","''","`",")",":","The","token","used","for","masking","values",".","This","is","the","token","used","when","training","this","model","with","masked","language","modeling",".","This","is","the","token","which","the","model","will","try","to","predict",".","Examples",":","``","`","python",">",">",">","from","transformers","import","MBart50TokenizerFast",">",">",">","tokenizer","=","MBart50TokenizerFast.from_pretrained","(","``","facebook\/mbart-large-50","''",",","src_lang=","''","en_XX","''",",","tgt_lang=","''","ro_RO","''",")",">",">",">","src_text","=","``","UN","Chief","Says","There","Is","No","Military","Solution","in","Syria","''",">",">",">","tgt_text","=","``","\u015eeful","ONU","declar\u0103","c\u0103","nu","exist\u0103","o","solu\u0163ie","militar\u0103","\u00een","Siria","''",">",">",">","model_inputs","=","tokenizer","(","src_text",",","text_target=tgt_text",",","return_tensors=","''","pt","''",")",">",">",">","#","model","(","*","*","model_inputs",")","should","work","``","`"]
code: def _switch_to_input_mode(self):
      return self.set_src_lang_special_tokens(self.src_lang)
  
file_path: H2O/h2o_flexgen/benchmark/third_party/transformers/src/transformers/models/mbart50/tokenization_mbart50_fast.py
imports: import os
  from shutil import copyfile
  from typing import List, Optional, Tuple
  from tokenizers import processors
  from ...tokenization_utils import AddedToken, BatchEncoding
  from ...tokenization_utils_fast import PreTrainedTokenizerFast
  from ...utils import is_sentencepiece_available, logging
label_desc: Use image node_id 6 for calling the MBart50TokenizerFast obj's underlying member method code with example usage: obj._switch_to_input_mode() and returns: self