






'''simple docstring'''





from collections import OrderedDict
from typing import Mapping

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


__A							:							Any  							=		logging.get_logger(__name__)

__A							:							Optional[Any]  							=		{
    """facebook/xlm-roberta-xl""": """https://huggingface.co/facebook/xlm-roberta-xl/resolve/main/config.json""",
    """facebook/xlm-roberta-xxl""": """https://huggingface.co/facebook/xlm-roberta-xxl/resolve/main/config.json""",
    # See all XLM-RoBERTa-XL models at https://huggingface.co/models?filter=xlm-roberta-xl
}
class 				lowercase       (							_lowerCamelCase      ):


    '''simple docstring'''

    lowerCAmelCase__      				=							"xlm-roberta-xl"

    def __init__(					self     :     List[Any]				,     __lowerCamelCase     :     Union[str, Any]=250880				,     __lowerCamelCase     :     Dict=2560				,     __lowerCamelCase     :     Union[str, Any]=36				,     __lowerCamelCase     :     Optional[int]=32				,     __lowerCamelCase     :     str=10240				,     __lowerCamelCase     :     Any="gelu"				,     __lowerCamelCase     :     Optional[Any]=0.1				,     __lowerCamelCase     :     Optional[int]=0.1				,     __lowerCamelCase     :     Tuple=514				,     __lowerCamelCase     :     Optional[Any]=1				,     __lowerCamelCase     :     Dict=0.0_2				,     __lowerCamelCase     :     Tuple=1E-05				,     __lowerCamelCase     :     Dict=1				,     __lowerCamelCase     :     int=0				,     __lowerCamelCase     :     Dict=2				,     __lowerCamelCase     :     List[Any]="absolute"				,     __lowerCamelCase     :     str=True				,     __lowerCamelCase     :     str=None				,     **__lowerCamelCase     :     List[str]				,     )							->							List[Any]:

          '''simple docstring'''




          super().__init__(pad_token_id=__lowerCamelCase				,     bos_token_id=__lowerCamelCase				,     eos_token_id=__lowerCamelCase				,     **__lowerCamelCase     )
          lowerCamelCase__  =     vocab_size
          lowerCamelCase__  =     hidden_size
          lowerCamelCase__  =     num_hidden_layers
          lowerCamelCase__  =     num_attention_heads
          lowerCamelCase__  =     hidden_act
          lowerCamelCase__  =     intermediate_size
          lowerCamelCase__  =     hidden_dropout_prob
          lowerCamelCase__  =     attention_probs_dropout_prob
          lowerCamelCase__  =     max_position_embeddings
          lowerCamelCase__  =     type_vocab_size
          lowerCamelCase__  =     initializer_range
          lowerCamelCase__  =     layer_norm_eps
          lowerCamelCase__  =     position_embedding_type
          lowerCamelCase__  =     use_cache
          lowerCamelCase__  =     classifier_dropout
class 				lowercase       (							_lowerCamelCase      ):


    '''simple docstring'''

    @property
    def    a__				(					self     :     List[Any]     )							->							Mapping[str, Mapping[int, str]]:

          '''simple docstring'''




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









'''simple docstring'''





from ..utils import DummyObject, requires_backends
class 				lowercase       (							metaclass=_lowerCamelCase      ):


    '''simple docstring'''

    lowerCAmelCase__      				=							["flax", "transformers"]

    def __init__(					self     :     List[str]				,     *__lowerCamelCase     :     int				,     **__lowerCamelCase     :     Any     )							->							Optional[int]:

     '''simple docstring'''




     requires_backends(self				,     ["flax", "transformers"]     )

    @classmethod
    def    a__				(					cls     :     Any				,     *__lowerCamelCase     :     Optional[int]				,     **__lowerCamelCase     :     Dict     )							->							str:

     '''simple docstring'''




     requires_backends(cls				,     ["flax", "transformers"]     )




    @classmethod
    def    a__				(					cls     :     str				,     *__lowerCamelCase     :     str				,     **__lowerCamelCase     :     Any     )							->							str:

     '''simple docstring'''




     requires_backends(cls				,     ["flax", "transformers"]     )
class 				lowercase       (							metaclass=_lowerCamelCase      ):


    '''simple docstring'''

    lowerCAmelCase__      				=							["flax", "transformers"]

    def __init__(					self     :     str				,     *__lowerCamelCase     :     List[Any]				,     **__lowerCamelCase     :     int     )							->							List[str]:

     '''simple docstring'''




     requires_backends(self				,     ["flax", "transformers"]     )

    @classmethod
    def    a__				(					cls     :     Dict				,     *__lowerCamelCase     :     Any				,     **__lowerCamelCase     :     str     )							->							Optional[int]:

     '''simple docstring'''




     requires_backends(cls				,     ["flax", "transformers"]     )




    @classmethod
    def    a__				(					cls     :     Any				,     *__lowerCamelCase     :     int				,     **__lowerCamelCase     :     Dict     )							->							int:

     '''simple docstring'''




     requires_backends(cls				,     ["flax", "transformers"]     )
class 				lowercase       (							metaclass=_lowerCamelCase      ):


    '''simple docstring'''

    lowerCAmelCase__      				=							["flax", "transformers"]

    def __init__(					self     :     Dict				,     *__lowerCamelCase     :     str				,     **__lowerCamelCase     :     List[Any]     )							->							str:

     '''simple docstring'''




     requires_backends(self				,     ["flax", "transformers"]     )

    @classmethod
    def    a__				(					cls     :     Optional[int]				,     *__lowerCamelCase     :     Optional[int]				,     **__lowerCamelCase     :     Optional[Any]     )							->							Dict:

     '''simple docstring'''




     requires_backends(cls				,     ["flax", "transformers"]     )




    @classmethod
    def    a__				(					cls     :     Optional[int]				,     *__lowerCamelCase     :     Dict				,     **__lowerCamelCase     :     List[str]     )							->							Dict:

     '''simple docstring'''




     requires_backends(cls				,     ["flax", "transformers"]     )
class 				lowercase       (							metaclass=_lowerCamelCase      ):


    '''simple docstring'''

    lowerCAmelCase__      				=							["flax", "transformers"]

    def __init__(					self     :     int				,     *__lowerCamelCase     :     List[str]				,     **__lowerCamelCase     :     int     )							->							Optional[int]:

     '''simple docstring'''




     requires_backends(self				,     ["flax", "transformers"]     )

    @classmethod
    def    a__				(					cls     :     Any				,     *__lowerCamelCase     :     Tuple				,     **__lowerCamelCase     :     str     )							->							List[str]:

     '''simple docstring'''




     requires_backends(cls				,     ["flax", "transformers"]     )




    @classmethod
    def    a__				(					cls     :     List[Any]				,     *__lowerCamelCase     :     List[str]				,     **__lowerCamelCase     :     List[Any]     )							->							int:

     '''simple docstring'''




     requires_backends(cls				,     ["flax", "transformers"]     )

