



"""simple docstring"""
from ...configuration_utils import PretrainedConfig
from ...utils import logging


__a      =				logging.get_logger(__name__)

__a      =				{
    "EleutherAI/gpt-neox-20b": "https://huggingface.co/EleutherAI/gpt-neox-20b/resolve/main/config.json",
    # See all GPTNeoX models at https://huggingface.co/models?filter=gpt_neox
}
class 				lowerCamelCase  (			_SCREAMING_SNAKE_CASE				):






					'''simple docstring'''





					_A		:			Optional[Any]						=     """gpt_neox"""






					def __init__(       self:							Optional[int]						,     snake_case:							Tuple=50_432						,     snake_case:							Optional[int]=6_144						,     snake_case:							Tuple=44						,     snake_case:							Any=64						,     snake_case:							List[Any]=24_576						,     snake_case:							List[Any]="gelu"						,     snake_case:							Optional[Any]=0.2_5						,     snake_case:							Any=10_000						,     snake_case:							Any=0.0						,     snake_case:							str=0.0						,     snake_case:							Optional[int]=0.1						,     snake_case:							List[Any]=2_048						,     snake_case:							List[Any]=0.0_2						,     snake_case:							Any=1E-5						,     snake_case:							Dict=True						,     snake_case:							Optional[int]=0						,     snake_case:							List[str]=2						,     snake_case:							Dict=False						,     snake_case:							Tuple=True						,     snake_case:							Optional[int]=None						,     **snake_case:							int						,     )   ->	Optional[Any]:
											super().__init__(bos_token_id=snake_case						,     eos_token_id=snake_case						,     **snake_case						)
											snake_case_ :Tuple						=			vocab_size
											snake_case_ :Union[str, Any]						=			max_position_embeddings
											snake_case_ :Any						=			hidden_size
											snake_case_ :List[Any]						=			num_hidden_layers
											snake_case_ :Optional[int]						=			num_attention_heads
											snake_case_ :str						=			intermediate_size
											snake_case_ :int						=			hidden_act
											snake_case_ :List[Any]						=			rotary_pct
											snake_case_ :Any						=			rotary_emb_base
											snake_case_ :List[str]						=			attention_dropout
											snake_case_ :Union[str, Any]						=			hidden_dropout
											snake_case_ :Tuple						=			classifier_dropout
											snake_case_ :Union[str, Any]						=			initializer_range
											snake_case_ :Any						=			layer_norm_eps
											snake_case_ :str						=			use_cache
											snake_case_ :str						=			tie_word_embeddings
											snake_case_ :str						=			use_parallel_residual
											snake_case_ :Any						=			rope_scaling
											self._rope_scaling_validation()

											if self.hidden_size % self.num_attention_heads != 0:
																	raise ValueError(
																	    """The hidden size is not divisble by the number of attention heads! Make sure to update them!"""						)






					def    lowerCAmelCase_				(       self:							List[str]						)   ->	List[str]:
											if self.rope_scaling is None:
																	return

											if not isinstance(self.rope_scaling						,     snake_case						) 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}"""						)
											snake_case_ :Optional[Any]						=			self.rope_scaling.get("""type"""						,     snake_case						)
											snake_case_ :int						=			self.rope_scaling.get("""factor"""						,     snake_case						)
											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(snake_case						,     snake_case						) 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'''






def 				UpperCamelCase_			(    A__					:   int					):
  '''simple docstring'''





  lowerCAmelCase_			:      Union[str, Any]			=   (1 + 24 * n) ** 0.5
  return ((1 + root) / 6) % 1 == 0







def 				UpperCamelCase_			(    A__					:   int = 50_00					):
  '''simple docstring'''





  lowerCAmelCase_			:      Optional[int]			=   [(i * (3 * i - 1)) // 2 for i in range(1							,    A__					)]
  for i, pentagonal_i in enumerate(A__					):
    for j in range(A__							,    len(A__					)					):
      lowerCAmelCase_			:      int			=   pentagonal_nums[j]
      lowerCAmelCase_			:      Union[str, Any]			=   pentagonal_i + pentagonal_j
      lowerCAmelCase_			:      List[Any]			=   pentagonal_j - pentagonal_i
      if is_pentagonal(A__					) and is_pentagonal(A__					):
        return b

  return -1


if __name__ == "__main__":
  print(F'''{solution() = }''')



