





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


_SCREAMING_SNAKE_CASE							=						logging.get_logger(__name__)

_SCREAMING_SNAKE_CASE							=						{
    """facebook/dpr-ctx_encoder-single-nq-base""": (
        """https://huggingface.co/facebook/dpr-ctx_encoder-single-nq-base/resolve/main/config.json"""
    ),
    """facebook/dpr-question_encoder-single-nq-base""": (
        """https://huggingface.co/facebook/dpr-question_encoder-single-nq-base/resolve/main/config.json"""
    ),
    """facebook/dpr-reader-single-nq-base""": (
        """https://huggingface.co/facebook/dpr-reader-single-nq-base/resolve/main/config.json"""
    ),
    """facebook/dpr-ctx_encoder-multiset-base""": (
        """https://huggingface.co/facebook/dpr-ctx_encoder-multiset-base/resolve/main/config.json"""
    ),
    """facebook/dpr-question_encoder-multiset-base""": (
        """https://huggingface.co/facebook/dpr-question_encoder-multiset-base/resolve/main/config.json"""
    ),
    """facebook/dpr-reader-multiset-base""": (
        """https://huggingface.co/facebook/dpr-reader-multiset-base/resolve/main/config.json"""
    ),
}
class SCREAMING_SNAKE_CASE_  (    snake_case_    ):
						__magic_name__:	Tuple       					=				'dpr'






						def __init__(					self					:					Union[str, Any]						,      _A					:					Any=30522						,      _A					:					Dict=768						,      _A					:					Dict=12						,      _A					:					Union[str, Any]=12						,      _A					:					Any=3072						,      _A					:					Tuple="gelu"						,      _A					:					Optional[int]=0.1						,      _A					:					Any=0.1						,      _A					:					List[str]=512						,      _A					:					str=2						,      _A					:					int=0.0_2						,      _A					:					Any=1E-12						,      _A					:					Tuple=0						,      _A					:					Union[str, Any]="absolute"						,      _A					:					List[str] = 0						,      **_A					:					str						,      )							->			Union[str, Any]:







							"""simple docstring"""


							super().__init__(pad_token_id=__lowerCAmelCase						,      **__lowerCAmelCase		)

							snake_case_						:	Dict      =		vocab_size
							snake_case_						:	Any      =		hidden_size
							snake_case_						:	List[str]      =		num_hidden_layers
							snake_case_						:	Dict      =		num_attention_heads
							snake_case_						:	int      =		hidden_act
							snake_case_						:	Optional[Any]      =		intermediate_size
							snake_case_						:	Dict      =		hidden_dropout_prob
							snake_case_						:	Union[str, Any]      =		attention_probs_dropout_prob
							snake_case_						:	Union[str, Any]      =		max_position_embeddings
							snake_case_						:	Any      =		type_vocab_size
							snake_case_						:	Any      =		initializer_range
							snake_case_						:	Dict      =		layer_norm_eps
							snake_case_						:	str      =		projection_dim
							snake_case_						:	Dict      =		position_embedding_type


"""simple docstring"""






from decimal import Decimal, getcontext
from math import ceil, factorial


def 			UpperCAmelCase__       (				lowerCAmelCase__     :int		) ->    str:
      '''simple docstring'''


      if not isinstance(lowerCAmelCase__					,		lowerCAmelCase__		):
            raise TypeError("""Undefined for non-integers"""		)
      elif precision < 1:
            raise ValueError("""Undefined for non-natural numbers"""		)

      lowercase														=	precision
      lowercase														=	ceil(precision / 1_4		)
      lowercase														=	4_2_6_8_8_0 * Decimal(1_0_0_0_5		).sqrt()
      lowercase														=	1
      lowercase														=	1_3_5_9_1_4_0_9
      lowercase														=	Decimal(lowerCAmelCase__		)
      for k in range(1					,		lowerCAmelCase__		):
            lowercase														=	factorial(6 * k		) // (factorial(3 * k		) * factorial(lowerCAmelCase__		) ** 3)
            linear_term += 5_4_5_1_4_0_1_3_4
            exponential_term *= -2_6_2_5_3_7_4_1_2_6_4_0_7_6_8_0_0_0
            partial_sum += Decimal(multinomial_term * linear_term		) / exponential_term
      return str(constant_term / partial_sum		)[:-1]


if __name__ == "__main__":
       __lowerCAmelCase    :       List[Any]					     =5_0
       print(F"""The first {n} digits of pi is: {pi(n)}""")



