






'''simple docstring'''







from collections import OrderedDict
from typing import Mapping

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


__lowerCAmelCase       		=      logging.get_logger(__name__)

__lowerCAmelCase       		=      {
    'xlm-roberta-base': 'https://huggingface.co/xlm-roberta-base/resolve/main/config.json',
    'xlm-roberta-large': 'https://huggingface.co/xlm-roberta-large/resolve/main/config.json',
    'xlm-roberta-large-finetuned-conll02-dutch': (
        'https://huggingface.co/xlm-roberta-large-finetuned-conll02-dutch/resolve/main/config.json'
    ),
    'xlm-roberta-large-finetuned-conll02-spanish': (
        'https://huggingface.co/xlm-roberta-large-finetuned-conll02-spanish/resolve/main/config.json'
    ),
    'xlm-roberta-large-finetuned-conll03-english': (
        'https://huggingface.co/xlm-roberta-large-finetuned-conll03-english/resolve/main/config.json'
    ),
    'xlm-roberta-large-finetuned-conll03-german': (
        'https://huggingface.co/xlm-roberta-large-finetuned-conll03-german/resolve/main/config.json'
    ),
}





class 	SCREAMING_SNAKE_CASE					(					SCREAMING_SNAKE_CASE_       ):
			snake_case__  =				"xlm-roberta"






			def __init__( self      :			Tuple  ,						__SCREAMING_SNAKE_CASE      :			Union[str, Any]=3_0522  ,						__SCREAMING_SNAKE_CASE      :			Any=768  ,						__SCREAMING_SNAKE_CASE      :			Dict=12  ,						__SCREAMING_SNAKE_CASE      :			Dict=12  ,						__SCREAMING_SNAKE_CASE      :			Any=3072  ,						__SCREAMING_SNAKE_CASE      :			Union[str, Any]="gelu"  ,						__SCREAMING_SNAKE_CASE      :			int=0.1  ,						__SCREAMING_SNAKE_CASE      :			Optional[int]=0.1  ,						__SCREAMING_SNAKE_CASE      :			str=512  ,						__SCREAMING_SNAKE_CASE      :			Optional[int]=2  ,						__SCREAMING_SNAKE_CASE      :			List[str]=0.02  ,						__SCREAMING_SNAKE_CASE      :			Optional[Any]=1e-12  ,						__SCREAMING_SNAKE_CASE      :			Tuple=1  ,						__SCREAMING_SNAKE_CASE      :			Tuple=0  ,						__SCREAMING_SNAKE_CASE      :			List[Any]=2  ,						__SCREAMING_SNAKE_CASE      :			Optional[int]="absolute"  ,						__SCREAMING_SNAKE_CASE      :			str=True  ,						__SCREAMING_SNAKE_CASE      :			List[str]=None  ,						**__SCREAMING_SNAKE_CASE      :			Union[str, Any]  ,						)			->			List[Any]:
							super().__init__(pad_token_id=__SCREAMING_SNAKE_CASE  ,						bos_token_id=__SCREAMING_SNAKE_CASE  ,						eos_token_id=__SCREAMING_SNAKE_CASE  ,						**__SCREAMING_SNAKE_CASE					)

							a_		:  int											=      vocab_size
							a_		:  Optional[Any]											=      hidden_size
							a_		:  Union[str, Any]											=      num_hidden_layers
							a_		:  Optional[int]											=      num_attention_heads
							a_		:  Tuple											=      hidden_act
							a_		:  Optional[int]											=      intermediate_size
							a_		:  Dict											=      hidden_dropout_prob
							a_		:  Optional[int]											=      attention_probs_dropout_prob
							a_		:  List[Any]											=      max_position_embeddings
							a_		:  Union[str, Any]											=      type_vocab_size
							a_		:  Tuple											=      initializer_range
							a_		:  List[str]											=      layer_norm_eps
							a_		:  Tuple											=      position_embedding_type
							a_		:  Tuple											=      use_cache
							a_		:  Optional[int]											=      classifier_dropout





class 	SCREAMING_SNAKE_CASE					(					SCREAMING_SNAKE_CASE_       ):






			@property
			def 			SCREAMING_SNAKE_CASE      ( self      :			Any					)			->			Mapping[str, Mapping[int, str]]:
							if self.task == "multiple-choice":
											a_		:  List[str]											=      {0: '''batch''', 1: '''choice''', 2: '''sequence'''}
							else:
											a_		:  str											=      {0: '''batch''', 1: '''sequence'''}
							return OrderedDict(
							    [
							        ('''input_ids''', dynamic_axis),
							        ('''attention_mask''', dynamic_axis),
							    ]					)












'''simple docstring'''







import warnings


warnings.warn(
    'memory_utils has been reorganized to utils.memory. Import `find_executable_batchsize` from the main `__init__`: '
    '`from accelerate import find_executable_batch_size` to avoid this warning.',
    FutureWarning,
)




