


from collections import OrderedDict
from typing import Mapping

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


snake_case							:	int					      =				logging.get_logger(__name__)

snake_case							:	Optional[Any]					      =				{
    '''facebook/xmod-base''': '''https://huggingface.co/facebook/xmod-base/resolve/main/config.json''',
    '''facebook/xmod-large-prenorm''': '''https://huggingface.co/facebook/xmod-large-prenorm/resolve/main/config.json''',
    '''facebook/xmod-base-13-125k''': '''https://huggingface.co/facebook/xmod-base-13-125k/resolve/main/config.json''',
    '''facebook/xmod-base-30-125k''': '''https://huggingface.co/facebook/xmod-base-30-125k/resolve/main/config.json''',
    '''facebook/xmod-base-30-195k''': '''https://huggingface.co/facebook/xmod-base-30-195k/resolve/main/config.json''',
    '''facebook/xmod-base-60-125k''': '''https://huggingface.co/facebook/xmod-base-60-125k/resolve/main/config.json''',
    '''facebook/xmod-base-60-265k''': '''https://huggingface.co/facebook/xmod-base-60-265k/resolve/main/config.json''',
    '''facebook/xmod-base-75-125k''': '''https://huggingface.co/facebook/xmod-base-75-125k/resolve/main/config.json''',
    '''facebook/xmod-base-75-269k''': '''https://huggingface.co/facebook/xmod-base-75-269k/resolve/main/config.json''',
}







class 	snake_case_       (lowerCamelCase_				):
					UpperCAmelCase__ :   List[Any]   				=      '''xmod'''
					def __init__(				self       :List[Any]      ,__snake_case       :Dict=3_05_22      ,__snake_case       :List[str]=7_68      ,__snake_case       :Optional[Any]=12      ,__snake_case       :Tuple=12      ,__snake_case       :List[Any]=30_72      ,__snake_case       :Optional[int]="gelu"      ,__snake_case       :Optional[int]=0.1      ,__snake_case       :Optional[Any]=0.1      ,__snake_case       :Tuple=5_12      ,__snake_case       :List[str]=2      ,__snake_case       :Optional[Any]=0.02      ,__snake_case       :int=1E-12      ,__snake_case       :Optional[Any]=1      ,__snake_case       :Union[str, Any]=0      ,__snake_case       :List[Any]=2      ,__snake_case       :List[str]="absolute"      ,__snake_case       :Optional[Any]=True      ,__snake_case       :str=None      ,__snake_case       :Optional[int]=False      ,__snake_case       :List[str]=2      ,__snake_case       :int=False      ,__snake_case       :List[Any]=True      ,__snake_case       :Tuple=True      ,__snake_case       :List[Any]=("en_XX",)      ,__snake_case       :str=None      ,**__snake_case       :str      ,) ->   Dict:
												super().__init__(pad_token_id=__snake_case      ,bos_token_id=__snake_case      ,eos_token_id=__snake_case      ,**__snake_case				)

												a__					=					vocab_size
												a__					=					hidden_size
												a__					=					num_hidden_layers
												a__					=					num_attention_heads
												a__					=					hidden_act
												a__					=					intermediate_size
												a__					=					hidden_dropout_prob
												a__					=					attention_probs_dropout_prob
												a__					=					max_position_embeddings
												a__					=					type_vocab_size
												a__					=					initializer_range
												a__					=					layer_norm_eps
												a__					=					position_embedding_type
												a__					=					use_cache
												a__					=					classifier_dropout
												a__					=					pre_norm
												a__					=					adapter_reduction_factor
												a__					=					adapter_layer_norm
												a__					=					adapter_reuse_layer_norm
												a__					=					ln_before_adapter
												a__					=					list(__snake_case				)
												a__					=					default_language







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








snake_case							:	str					      =				{
    0: '''0''',
    1: '''1''',
    2: '''2''',
    3: '''3''',
    4: '''4''',
    5: '''5''',
    6: '''6''',
    7: '''7''',
    8: '''8''',
    9: '''9''',
    10: '''a''',
    11: '''b''',
    12: '''c''',
    13: '''d''',
    14: '''e''',
    15: '''f''',
}






def 							__lowercase       (			__lowerCAmelCase							:    float       ):
							assert type(__lowerCAmelCase       ) in (int, float) and decimal == int(__lowerCAmelCase       )
							a__					=					int(__lowerCAmelCase       )
							a__					=					''
							a__					=					False
							if decimal < 0:
														a__					=					True
														decimal *= -1
							while decimal > 0:
														a__				, a__					=					divmod(__lowerCAmelCase ,   1_6       )
														a__					=					values[remainder] + hexadecimal
							a__					=					'0x' + hexadecimal
							if negative:
														a__					=					'-' + hexadecimal
							return hexadecimal


if __name__ == "__main__":
						import doctest

						doctest.testmod()




