






"""simple docstring"""





from typing import Callable, Optional, Union

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


UpperCamelCase_						:					int      				=			logging.get_logger(__name__)

UpperCamelCase_						:					int      				=			{
    """microsoft/prophetnet-large-uncased""": (
        """https://huggingface.co/microsoft/prophetnet-large-uncased/resolve/main/config.json"""
    ),
}


class   _lowercase			(  lowerCAmelCase    ):
      _a :  Optional[Any]										= '''prophetnet'''
      _a :  str										= ['''past_key_values''']
      _a :  Union[str, Any]										= {
          '''num_attention_heads''': '''num_encoder_attention_heads''',
      }


      def __init__(     self					:						Optional[Any]				, a					:						Optional[float] = 0.1				, a					:						Optional[Union[str, Callable]] = "gelu"				, a					:						Optional[int] = 3_0_5_2_2				, a					:						Optional[int] = 1_0_2_4				, a					:						Optional[int] = 4_0_9_6				, a					:						Optional[int] = 1_2				, a					:						Optional[int] = 1_6				, a					:						Optional[int] = 4_0_9_6				, a					:						Optional[int] = 1_2				, a					:						Optional[int] = 1_6				, a					:						Optional[float] = 0.1				, a					:						Optional[float] = 0.1				, a					:						Optional[int] = 5_1_2				, a					:						Optional[float] = 0.0_2				, a					:						Optional[bool] = True				, a					:						Optional[bool] = True				, a					:						Optional[int] = 0				, a					:						Optional[int] = 2				, a					:						Optional[int] = 3_2				, a					:						Optional[int] = 1_2_8				, a					:						Optional[bool] = False				, a					:						Optional[float] = 0.0				, a					:						Optional[bool] = True				, a					:						Optional[int] = 0				, a					:						Optional[int] = 1				, a					:						Optional[int] = 2				, **a					:						Optional[int]				, ):





            """simple docstring"""







            __snake_case   :     int	      =vocab_size
            __snake_case   :     Dict	      =hidden_size
            __snake_case   :     int	      =encoder_ffn_dim
            __snake_case   :     Dict	      =num_encoder_layers
            __snake_case   :     Optional[int]	      =num_encoder_attention_heads
            __snake_case   :     List[str]	      =decoder_ffn_dim
            __snake_case   :     Any	      =num_decoder_layers
            __snake_case   :     str	      =num_decoder_attention_heads
            __snake_case   :     Dict	      =max_position_embeddings
            __snake_case   :     Optional[Any]	      =init_std  # Normal(0, this parameter)
            __snake_case   :     List[str]	      =activation_function

            # parameters for prophetnet
            __snake_case   :     Union[str, Any]	      =ngram
            __snake_case   :     List[Any]	      =num_buckets
            __snake_case   :     Optional[int]	      =relative_max_distance
            __snake_case   :     Dict	      =disable_ngram_loss
            __snake_case   :     Union[str, Any]	      =eps

            # 3 Types of Dropout
            __snake_case   :     List[str]	      =attention_dropout
            __snake_case   :     Any	      =activation_dropout
            __snake_case   :     Optional[int]	      =dropout

            __snake_case   :     Dict	      =use_cache

            super().__init__(
                pad_token_id=a				, bos_token_id=a				, eos_token_id=a				, is_encoder_decoder=a				, add_cross_attention=a				, decoder_start_token_id=a				, **a				, )


      @property
      def _UpperCamelCase    (     self					:						Optional[int]    ):





            """simple docstring"""







            return self.num_encoder_layers + self.num_decoder_layers







      @num_hidden_layers.setter
      def _UpperCamelCase    (     self					:						List[str]				, a					:						Union[str, Any]    ):





            """simple docstring"""







            raise NotImplementedError(
                '''This model does not support the setting of `num_hidden_layers`. Please set `num_encoder_layers` and'''
                ''' `num_decoder_layers`.'''    )










"""simple docstring"""





from itertools import combinations, product



def      __lowercase       (     a			:					int							,		a			:					int							,		a			:					int							,		a			:					int			)       ->       bool:
      if xa == ya == 0 or xa == ya == 0:
            return False
      __snake_case   :     Any	      =xa * xa + ya * ya
      __snake_case   :     Tuple	      =xa * xa + ya * ya
      __snake_case   :     List[Any]	      =(xa - xa) * (xa - xa) + (ya - ya) * (ya - ya)
      return (
          a_square + b_square == c_square
          or a_square + c_square == b_square
          or b_square + c_square == a_square
      )



def      __lowercase       (     a			:					int = 50			)       ->       int:
      return sum(
          1
          for pta, pta in combinations(product(range(limit + 1			)							,		repeat=2			)							,		2			)
          if is_right(*a							,		*a			)			)


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


