






"""simple docstring"""






from ...configuration_utils import PretrainedConfig
from ...utils import logging


UpperCAmelCase_   : Union[str, Any]   			= logging.get_logger(__name__)

UpperCAmelCase_   : Optional[int]   			= {}




class 							lowerCAmelCase__				(			UpperCAmelCase__ ):






      '''simple docstring'''

      __UpperCamelCase	 =  "llama"
      __UpperCamelCase	 =  ["past_key_values"]
      def __init__(						self     :  Union[str, Any]						,	lowercase_     :  Union[str, Any]=32000						,	lowercase_     :  Union[str, Any]=4096						,	lowercase_     :  Tuple=11008						,	lowercase_     :  Any=32						,	lowercase_     :  Dict=32						,	lowercase_     :  Dict=None						,	lowercase_     :  List[str]="silu"						,	lowercase_     :  Dict=2048						,	lowercase_     :  str=0.02						,	lowercase_     :  str=1e-6						,	lowercase_     :  Optional[int]=True						,	lowercase_     :  Optional[Any]=0						,	lowercase_     :  Any=1						,	lowercase_     :  Optional[int]=2						,	lowercase_     :  Tuple=1						,	lowercase_     :  Optional[int]=False						,	lowercase_     :  Tuple=None						,	**lowercase_     :  Union[str, Any]						,	):




          '''simple docstring'''


          SCREAMING_SNAKE_CASE_      :  str    						=		vocab_size
          SCREAMING_SNAKE_CASE_      :  Union[str, Any]    						=		max_position_embeddings
          SCREAMING_SNAKE_CASE_      :  Optional[int]    						=		hidden_size
          SCREAMING_SNAKE_CASE_      :  Optional[Any]    						=		intermediate_size
          SCREAMING_SNAKE_CASE_      :  List[Any]    						=		num_hidden_layers
          SCREAMING_SNAKE_CASE_      :  int    						=		num_attention_heads

          # for backward compatibility
          if num_key_value_heads is None:
              SCREAMING_SNAKE_CASE_      :  Tuple    						=		num_attention_heads

          SCREAMING_SNAKE_CASE_      :  Tuple    						=		num_key_value_heads
          SCREAMING_SNAKE_CASE_      :  Optional[int]    						=		hidden_act
          SCREAMING_SNAKE_CASE_      :  Optional[Any]    						=		initializer_range
          SCREAMING_SNAKE_CASE_      :  int    						=		rms_norm_eps
          SCREAMING_SNAKE_CASE_      :  List[Any]    						=		pretraining_tp
          SCREAMING_SNAKE_CASE_      :  Any    						=		use_cache
          SCREAMING_SNAKE_CASE_      :  int    						=		rope_scaling
          self._rope_scaling_validation()

          super().__init__(
              pad_token_id=lowercase_						,	bos_token_id=lowercase_						,	eos_token_id=lowercase_						,	tie_word_embeddings=lowercase_						,	**lowercase_						,	)



      def _SCREAMING_SNAKE_CASE (						self     :  Optional[Any]):




          '''simple docstring'''


          if self.rope_scaling is None:
              return

          if not isinstance(self.rope_scaling						,	lowercase_) or len(self.rope_scaling) != 2:
              raise ValueError(
                  '''`rope_scaling` must be a dictionary with with two fields, `name` and `factor`, '''
                  F'got {self.rope_scaling}')
          SCREAMING_SNAKE_CASE_      :  Any    						=		self.rope_scaling.get('''type'''						,	lowercase_)
          SCREAMING_SNAKE_CASE_      :  Tuple    						=		self.rope_scaling.get('''factor'''						,	lowercase_)
          if rope_scaling_type is None or rope_scaling_type not in ["linear", "dynamic"]:
              raise ValueError(
                  F'`rope_scaling`\'s name field must be one of [\'linear\', \'dynamic\'], got {rope_scaling_type}')
          if rope_scaling_factor is None or not isinstance(lowercase_						,	lowercase_) or rope_scaling_factor <= 1.0:
              raise ValueError(F'`rope_scaling`\'s factor field must be an float > 1, got {rope_scaling_factor}')










"""simple docstring"""






from math import factorial



def 					_A			(__a = 20							) ->       int:
    """simple docstring"""






    SCREAMING_SNAKE_CASE_      :  Dict    						=		2 * n  # middle entry of odd rows starting at row 3 is the solution for n = 1,
    # 2, 3,...
    SCREAMING_SNAKE_CASE_      :  List[str]    						=		n // 2

    return int(factorial(__a							) / (factorial(__a							) * factorial(n - k							))							)


if __name__ == "__main__":
  import sys

  if len(sys.argv) == 1:
    print(solution(20))
  else:
    try:
      UpperCAmelCase_   : List[str]   			= int(sys.argv[1])
      print(solution(n))
    except ValueError:
      print("""Invalid entry - please enter a number.""")


