

'''simple docstring'''
from collections import OrderedDict
from typing import Mapping

from ...configuration_utils import PretrainedConfig
from ...onnx import OnnxConfig
from ...utils import logging


lowerCamelCase :      str					 =     logging.get_logger(__name__)

lowerCamelCase :      Dict					 =     {
    "google/bigbird-roberta-base": "https://huggingface.co/google/bigbird-roberta-base/resolve/main/config.json",
    "google/bigbird-roberta-large": "https://huggingface.co/google/bigbird-roberta-large/resolve/main/config.json",
    "google/bigbird-base-trivia-itc": "https://huggingface.co/google/bigbird-base-trivia-itc/resolve/main/config.json",
    # See all BigBird models at https://huggingface.co/models?filter=big_bird
}







class 							A__    (       A__  ):
  A__		 =				'big_bird'





  def __init__(		self      :	Any							,					_a      :	Dict=5_0358							,					_a      :	int=768							,					_a      :	Tuple=12							,					_a      :	Dict=12							,					_a      :	Optional[Any]=3072							,					_a      :	Dict="gelu_new"							,					_a      :	str=0.1							,					_a      :	str=0.1							,					_a      :	Any=4096							,					_a      :	Dict=2							,					_a      :	Optional[Any]=0.02							,					_a      :	Union[str, Any]=1e-12							,					_a      :	List[Any]=True							,					_a      :	Dict=0							,					_a      :	Union[str, Any]=1							,					_a      :	List[str]=2							,					_a      :	int=66							,					_a      :	Optional[int]="block_sparse"							,					_a      :	Any=True							,					_a      :	Union[str, Any]=False							,					_a      :	str=64							,					_a      :	Optional[Any]=3							,					_a      :	List[str]=None							,					**_a      :	List[str]							,					)	->    str:





       '''simple docstring'''






       super().__init__(
           pad_token_id=_a							,					bos_token_id=_a							,					eos_token_id=_a							,					sep_token_id=_a							,					**_a							,					)

       _SCREAMING_SNAKE_CASE							    =vocab_size
       _SCREAMING_SNAKE_CASE							    =max_position_embeddings
       _SCREAMING_SNAKE_CASE							    =hidden_size
       _SCREAMING_SNAKE_CASE							    =num_hidden_layers
       _SCREAMING_SNAKE_CASE							    =num_attention_heads
       _SCREAMING_SNAKE_CASE							    =intermediate_size
       _SCREAMING_SNAKE_CASE							    =hidden_act
       _SCREAMING_SNAKE_CASE							    =hidden_dropout_prob
       _SCREAMING_SNAKE_CASE							    =attention_probs_dropout_prob
       _SCREAMING_SNAKE_CASE							    =initializer_range
       _SCREAMING_SNAKE_CASE							    =type_vocab_size
       _SCREAMING_SNAKE_CASE							    =layer_norm_eps
       _SCREAMING_SNAKE_CASE							    =use_cache

       _SCREAMING_SNAKE_CASE							    =rescale_embeddings
       _SCREAMING_SNAKE_CASE							    =attention_type
       _SCREAMING_SNAKE_CASE							    =use_bias
       _SCREAMING_SNAKE_CASE							    =block_size
       _SCREAMING_SNAKE_CASE							    =num_random_blocks
       _SCREAMING_SNAKE_CASE							    =classifier_dropout







class 							A__    (       A__  ):





  @property
  def 						A  (		self      :	Optional[int] )	->    Mapping[str, Mapping[int, str]]:





       '''simple docstring'''






       if self.task == "multiple-choice":
            _SCREAMING_SNAKE_CASE							    ={0: 'batch', 1: 'choice', 2: 'sequence'}
       else:
            _SCREAMING_SNAKE_CASE							    ={0: 'batch', 1: 'sequence'}
       return OrderedDict(
           [
               ('input_ids', dynamic_axis),
               ('attention_mask', dynamic_axis),
           ] )



'''simple docstring'''
from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_flax_available,
    is_sentencepiece_available,
    is_tf_available,
    is_tokenizers_available,
    is_torch_available,
)


lowerCamelCase :      int					 =     {"configuration_mbart": ["MBART_PRETRAINED_CONFIG_ARCHIVE_MAP", "MBartConfig", "MBartOnnxConfig"]}

try:
     if not is_sentencepiece_available():
          raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
     pass
else:
     lowerCamelCase :      List[Any]					 =     ["MBartTokenizer"]

try:
     if not is_tokenizers_available():
          raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
     pass
else:
     lowerCamelCase :      Dict					 =     ["MBartTokenizerFast"]

try:
     if not is_torch_available():
          raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
     pass
else:
     lowerCamelCase :      int					 =     [
         "MBART_PRETRAINED_MODEL_ARCHIVE_LIST",
         "MBartForCausalLM",
         "MBartForConditionalGeneration",
         "MBartForQuestionAnswering",
         "MBartForSequenceClassification",
         "MBartModel",
         "MBartPreTrainedModel",
     ]

try:
     if not is_tf_available():
          raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
     pass
else:
     lowerCamelCase :      Union[str, Any]					 =     [
         "TFMBartForConditionalGeneration",
         "TFMBartModel",
         "TFMBartPreTrainedModel",
     ]

try:
     if not is_flax_available():
          raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
     pass
else:
     lowerCamelCase :      Optional[Any]					 =     [
         "FlaxMBartForConditionalGeneration",
         "FlaxMBartForQuestionAnswering",
         "FlaxMBartForSequenceClassification",
         "FlaxMBartModel",
         "FlaxMBartPreTrainedModel",
     ]


if TYPE_CHECKING:
     from .configuration_mbart import MBART_PRETRAINED_CONFIG_ARCHIVE_MAP, MBartConfig, MBartOnnxConfig

     try:
          if not is_sentencepiece_available():
               raise OptionalDependencyNotAvailable()
     except OptionalDependencyNotAvailable:
          pass
     else:
          from .tokenization_mbart import MBartTokenizer

     try:
          if not is_tokenizers_available():
               raise OptionalDependencyNotAvailable()
     except OptionalDependencyNotAvailable:
          pass
     else:
          from .tokenization_mbart_fast import MBartTokenizerFast

     try:
          if not is_torch_available():
               raise OptionalDependencyNotAvailable()
     except OptionalDependencyNotAvailable:
          pass
     else:
          from .modeling_mbart import (
              MBART_PRETRAINED_MODEL_ARCHIVE_LIST,
              MBartForCausalLM,
              MBartForConditionalGeneration,
              MBartForQuestionAnswering,
              MBartForSequenceClassification,
              MBartModel,
              MBartPreTrainedModel,
          )

     try:
          if not is_tf_available():
               raise OptionalDependencyNotAvailable()
     except OptionalDependencyNotAvailable:
          pass
     else:
          from .modeling_tf_mbart import TFMBartForConditionalGeneration, TFMBartModel, TFMBartPreTrainedModel

     try:
          if not is_flax_available():
               raise OptionalDependencyNotAvailable()
     except OptionalDependencyNotAvailable:
          pass
     else:
          from .modeling_flax_mbart import (
              FlaxMBartForConditionalGeneration,
              FlaxMBartForQuestionAnswering,
              FlaxMBartForSequenceClassification,
              FlaxMBartModel,
              FlaxMBartPreTrainedModel,
          )

else:
     import sys

     lowerCamelCase :      List[Any]					 =     _LazyModule(__name__, globals()["__file__"], _import_structure, module_spec=__spec__)
