
from __future__ import annotations

from typing import Dict

from ...configuration_utils import PretrainedConfig


_snake_case      = {
    '''susnato/ernie-m-base_pytorch''': '''https://huggingface.co/susnato/ernie-m-base_pytorch/blob/main/config.json''',
    '''susnato/ernie-m-large_pytorch''': '''https://huggingface.co/susnato/ernie-m-large_pytorch/blob/main/config.json''',
}
class       _lowerCAmelCase  (		__magic_name__							):

 """simple docstring"""
 SCREAMING_SNAKE_CASE_				:					Optional[int]       						="ernie_m"
 SCREAMING_SNAKE_CASE_				:					Dict[str, str]       						={"dropout": "classifier_dropout", "num_classes": "num_labels"}

 def __init__(						self			:			int					, SCREAMING_SNAKE_CASE__			:			int = 25_00_02					, SCREAMING_SNAKE_CASE__			:			int = 7_68					, SCREAMING_SNAKE_CASE__			:			int = 12					, SCREAMING_SNAKE_CASE__			:			int = 12					, SCREAMING_SNAKE_CASE__			:			int = 30_72					, SCREAMING_SNAKE_CASE__			:			str = "gelu"					, SCREAMING_SNAKE_CASE__			:			float = 0.1					, SCREAMING_SNAKE_CASE__			:			float = 0.1					, SCREAMING_SNAKE_CASE__			:			int = 5_14					, SCREAMING_SNAKE_CASE__			:			float = 0.02					, SCREAMING_SNAKE_CASE__			:			int = 1					, SCREAMING_SNAKE_CASE__			:			float = 1e-05					, SCREAMING_SNAKE_CASE__			:			Any=None					, SCREAMING_SNAKE_CASE__			:			Union[str, Any]=False					, SCREAMING_SNAKE_CASE__			:			int=0.0					, **SCREAMING_SNAKE_CASE__			:			Optional[int]					, ):






      """simple docstring"""



      super().__init__(pad_token_id=SCREAMING_SNAKE_CASE__					, **SCREAMING_SNAKE_CASE__   )
      UpperCamelCase						    =					vocab_size
      UpperCamelCase						    =					hidden_size
      UpperCamelCase						    =					num_hidden_layers
      UpperCamelCase						    =					num_attention_heads
      UpperCamelCase						    =					intermediate_size
      UpperCamelCase						    =					hidden_act
      UpperCamelCase						    =					hidden_dropout_prob
      UpperCamelCase						    =					attention_probs_dropout_prob
      UpperCamelCase						    =					max_position_embeddings
      UpperCamelCase						    =					initializer_range
      UpperCamelCase						    =					layer_norm_eps
      UpperCamelCase						    =					classifier_dropout
      UpperCamelCase						    =					is_decoder
      UpperCamelCase						    =					act_dropout




from functools import lru_cache

@lru_cache
def  __lowerCamelCase					( _lowercase			)       ->      int:
     if num < 0:
          raise ValueError('Number should not be negative.'			)

     return 1 if num in (0, 1) else num * factorial(num - 1			)


if __name__ == "__main__":
 import doctest

 doctest.testmod()


