



from math import factorial, pi







def    _snake_case (       __snake_case					,  __snake_case = 3_0    )     ->     float:






      '''simple docstring'''







      if not isinstance(__snake_case					,  (int, float)    ):
            raise ValueError("maclaurin_sin() requires either an int or float for theta"    )

      if not isinstance(__snake_case					,  __snake_case    ) or accuracy <= 0:
            raise ValueError("maclaurin_sin() requires a positive int for accuracy"    )

      UpperCAmelCase_  :	List[Any]				      =		float(__snake_case    )
      UpperCAmelCase_  :	Tuple				      =		theta // (2 * pi)
      theta -= 2 * div * pi
      return sum(
          (-1) ** r * theta ** (2 * r + 1) / factorial(2 * r + 1    ) for r in range(__snake_case    )    )







def    _snake_case (       __snake_case					,  __snake_case = 3_0    )     ->     float:






      '''simple docstring'''







      if not isinstance(__snake_case					,  (int, float)    ):
            raise ValueError("maclaurin_cos() requires either an int or float for theta"    )

      if not isinstance(__snake_case					,  __snake_case    ) or accuracy <= 0:
            raise ValueError("maclaurin_cos() requires a positive int for accuracy"    )

      UpperCAmelCase_  :	List[Any]				      =		float(__snake_case    )
      UpperCAmelCase_  :	int				      =		theta // (2 * pi)
      theta -= 2 * div * pi
      return sum((-1) ** r * theta ** (2 * r) / factorial(2 * r    ) for r in range(__snake_case    )    )


if __name__ == "__main__":
   import doctest

   doctest.testmod()

   print(maclaurin_sin(10))
   print(maclaurin_sin(-10))
   print(maclaurin_sin(10, 15))
   print(maclaurin_sin(-10, 15))

   print(maclaurin_cos(5))
   print(maclaurin_cos(-5))
   print(maclaurin_cos(10, 15))
   print(maclaurin_cos(-10, 15))





import logging

from transformers import PretrainedConfig


__lowerCamelCase         =			logging.getLogger(__name__)


__lowerCamelCase         =			{
    '''bertabs-finetuned-cnndm''': '''https://huggingface.co/remi/bertabs-finetuned-cnndm-extractive-abstractive-summarization/resolve/main/config.json''',
}


class   snake_case_ (lowercase__  ):




       """simple docstring"""






       _lowerCamelCase			    =				"""bertabs"""



       def __init__(     self     ,lowercase=30522     ,lowercase=512     ,lowercase=6     ,lowercase=512     ,lowercase=8     ,lowercase=512     ,lowercase=0.2     ,lowercase=6     ,lowercase=768     ,lowercase=8     ,lowercase=2048     ,lowercase=0.2     ,**lowercase     ,):

             """simple docstring"""





             super().__init__(**lowercase)

             UpperCAmelCase_  :	Any				      =		vocab_size
             UpperCAmelCase_  :	int				      =		max_pos

             UpperCAmelCase_  :	List[str]				      =		enc_layers
             UpperCAmelCase_  :	List[str]				      =		enc_hidden_size
             UpperCAmelCase_  :	Any				      =		enc_heads
             UpperCAmelCase_  :	Any				      =		enc_ff_size
             UpperCAmelCase_  :	Optional[int]				      =		enc_dropout

             UpperCAmelCase_  :	List[str]				      =		dec_layers
             UpperCAmelCase_  :	List[Any]				      =		dec_hidden_size
             UpperCAmelCase_  :	List[str]				      =		dec_heads
             UpperCAmelCase_  :	List[Any]				      =		dec_ff_size
             UpperCAmelCase_  :	List[str]				      =		dec_dropout
