




"""simple docstring"""





from collections import OrderedDict
from typing import Mapping

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


_lowercase						   =     logging.get_logger(__name__)

_lowercase						   =     {
    """google/electra-small-generator""": """https://huggingface.co/google/electra-small-generator/resolve/main/config.json""",
    """google/electra-base-generator""": """https://huggingface.co/google/electra-base-generator/resolve/main/config.json""",
    """google/electra-large-generator""": """https://huggingface.co/google/electra-large-generator/resolve/main/config.json""",
    """google/electra-small-discriminator""": (
        """https://huggingface.co/google/electra-small-discriminator/resolve/main/config.json"""
    ),
    """google/electra-base-discriminator""": (
        """https://huggingface.co/google/electra-base-discriminator/resolve/main/config.json"""
    ),
    """google/electra-large-discriminator""": (
        """https://huggingface.co/google/electra-large-discriminator/resolve/main/config.json"""
    ),
}

class    __lowercase							(      snake_case_						):


				'''simple docstring'''


				_lowerCAmelCase						      ="electra"

				def __init__( self :  Any   ,SCREAMING_SNAKE_CASE_ :  Tuple=3_0_5_2_2   ,SCREAMING_SNAKE_CASE_ :  List[str]=1_2_8   ,SCREAMING_SNAKE_CASE_ :  List[Any]=2_5_6   ,SCREAMING_SNAKE_CASE_ :  Tuple=1_2   ,SCREAMING_SNAKE_CASE_ :  Union[str, Any]=4   ,SCREAMING_SNAKE_CASE_ :  str=1_0_2_4   ,SCREAMING_SNAKE_CASE_ :  Dict="gelu"   ,SCREAMING_SNAKE_CASE_ :  List[str]=0.1   ,SCREAMING_SNAKE_CASE_ :  Any=0.1   ,SCREAMING_SNAKE_CASE_ :  Optional[Any]=5_1_2   ,SCREAMING_SNAKE_CASE_ :  str=2   ,SCREAMING_SNAKE_CASE_ :  Union[str, Any]=0.02   ,SCREAMING_SNAKE_CASE_ :  List[Any]=1E-12   ,SCREAMING_SNAKE_CASE_ :  Optional[Any]="first"   ,SCREAMING_SNAKE_CASE_ :  List[str]=True   ,SCREAMING_SNAKE_CASE_ :  Optional[int]="gelu"   ,SCREAMING_SNAKE_CASE_ :  List[Any]=0.1   ,SCREAMING_SNAKE_CASE_ :  Union[str, Any]=0   ,SCREAMING_SNAKE_CASE_ :  Optional[Any]="absolute"   ,SCREAMING_SNAKE_CASE_ :  List[Any]=True   ,SCREAMING_SNAKE_CASE_ :  Tuple=None   ,**SCREAMING_SNAKE_CASE_ :  Dict   ,):
										super().__init__(pad_token_id=SCREAMING_SNAKE_CASE_   ,**SCREAMING_SNAKE_CASE_   )

										snake_case__							:       List[Any]				      =       vocab_size
										snake_case__							:       str				      =       embedding_size
										snake_case__							:       Any				      =       hidden_size
										snake_case__							:       Dict				      =       num_hidden_layers
										snake_case__							:       Optional[int]				      =       num_attention_heads
										snake_case__							:       Optional[int]				      =       intermediate_size
										snake_case__							:       Any				      =       hidden_act
										snake_case__							:       Union[str, Any]				      =       hidden_dropout_prob
										snake_case__							:       Dict				      =       attention_probs_dropout_prob
										snake_case__							:       List[str]				      =       max_position_embeddings
										snake_case__							:       Dict				      =       type_vocab_size
										snake_case__							:       Optional[Any]				      =       initializer_range
										snake_case__							:       Optional[Any]				      =       layer_norm_eps

										snake_case__							:       Optional[Any]				      =       summary_type
										snake_case__							:       Dict				      =       summary_use_proj
										snake_case__							:       Dict				      =       summary_activation
										snake_case__							:       int				      =       summary_last_dropout
										snake_case__							:       Any				      =       position_embedding_type
										snake_case__							:       Dict				      =       use_cache
										snake_case__							:       str				      =       classifier_dropout







class    __lowercase							(      snake_case_						):


				'''simple docstring'''


				@property
				def    _lowerCamelCase       ( self :  List[str]   ):
										if self.task == "multiple-choice":
																snake_case__							:       str				      =       {0: '''batch''', 1: '''choice''', 2: '''sequence'''}
										else:
																snake_case__							:       Optional[Any]				      =       {0: '''batch''', 1: '''sequence'''}
										return OrderedDict(
										    [
										        ('''input_ids''', dynamic_axis),
										        ('''attention_mask''', dynamic_axis),
										        ('''token_type_ids''', dynamic_axis),
										    ]   )








"""simple docstring"""





_lowercase						   =     (1, 1_53, 3_70, 3_71, 16_34, 24_67_80_51, 1_15_13_22_19_01_87_63_99_25_65_09_55_97_97_39_71_52_24_01)
_lowercase						   =     (-1_53, -1, 0, 1.2, 2_00, "A", [], {}, None)

def 		lowerCAmelCase				(			lowerCamelCase		):
						'''simple docstring'''


						if not isinstance(lowerCamelCase   ,      lowerCamelCase		) or n < 1:
												return False

						# Initialization of sum and number of digits.
						snake_case__							:       Optional[Any]				      =       0
						snake_case__							:       Union[str, Any]				      =       0
						snake_case__							:       List[str]				      =       n
						# Calculation of digits of the number
						while temp > 0:
												number_of_digits += 1
												temp //= 10
						# Dividing number into separate digits and find Armstrong number
						snake_case__							:       Optional[int]				      =       n
						while temp > 0:
												snake_case__							:       Optional[int]				      =       temp % 10
												total += rem**number_of_digits
												temp //= 10
						return n == total

def 		lowerCAmelCase				(			lowerCamelCase		):
						'''simple docstring'''


						if not isinstance(lowerCamelCase   ,      lowerCamelCase		) or n < 1:
												return False

						# Init a "histogram" of the digits
						snake_case__							:       Union[str, Any]				      =       [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
						snake_case__							:       int				      =       0
						snake_case__							:       int				      =       0
						snake_case__							:       Dict				      =       n
						while temp > 0:
												snake_case__      ,						snake_case__							:       Optional[int]				      =       divmod(lowerCamelCase   ,      10		)
												digit_histogram[rem] += 1
												digit_total += 1

						for cnt, i in zip(lowerCamelCase   ,      range(len(lowerCamelCase		)		)		):
												total += cnt * i**digit_total

						return n == total

def 		lowerCAmelCase				(			lowerCamelCase		):
						'''simple docstring'''


						if not isinstance(lowerCamelCase   ,      lowerCamelCase		) or n < 1:
												return False
						snake_case__							:       Union[str, Any]				      =       len(str(lowerCamelCase		)		)  # the power that all digits will be raised to
						# check if sum of each digit multiplied expo times is equal to number
						return n == sum(int(lowerCamelCase		) ** expo for i in str(lowerCamelCase		)		)

def 		lowerCAmelCase				(			):
						'''simple docstring'''


						snake_case__							:       Dict				      =       int(input('''Enter an integer to see if it is an Armstrong number: '''		).strip()		)
						print(f'''{num} is {'' if armstrong_number(lowerCamelCase		) else 'not '}an Armstrong number.'''		)
						print(f'''{num} is {'' if narcissistic_number(lowerCamelCase		) else 'not '}an Armstrong number.'''		)
						print(f'''{num} is {'' if pluperfect_number(lowerCamelCase		) else 'not '}an Armstrong number.'''		)


if __name__ == "__main__":
							import doctest

							doctest.testmod()
							main()


