


'''simple docstring'''







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


lowerCAmelCase    :     List[Any]					=						logging.get_logger(__name__)

lowerCAmelCase    :     int					=						{
    """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 	UpperCamelCase__					( SCREAMING_SNAKE_CASE_	):



     """simple docstring"""






     __magic_name__    			=    "dpr"







     def __init__( self      ,	snake_case__=3_0522      ,	snake_case__=768      ,	snake_case__=12      ,	snake_case__=12      ,	snake_case__=3072      ,	snake_case__="gelu"      ,	snake_case__=0.1      ,	snake_case__=0.1      ,	snake_case__=512      ,	snake_case__=2      ,	snake_case__=0.02      ,	snake_case__=1E-12      ,	snake_case__=0      ,	snake_case__="absolute"      ,	snake_case__ = 0      ,	**snake_case__      ,	):

            '''simple docstring'''

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

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





'''simple docstring'''







lowerCAmelCase    :     Optional[int]					=						[sum(int(c, 10) ** 2 for c in i.__str__()) for i in range(10_00_00)]






def 			lowercase				(_A					):







       """simple docstring"""







       _lowerCAmelCase    :							str   			=       0
       while number:
              # Increased Speed Slightly by checking every 5 digits together.
              sum_of_digits_squared += DIGITS_SQUARED[number % 1_0_0_0_0_0]
              number //= 1_0_0_0_0_0

       return sum_of_digits_squared


# There are 2 Chains made,
# One ends with 89 with the chain member 58 being the one which when declared first,
# there will be the least number of iterations for all the members to be checked.

# The other one ends with 1 and has only one element 1.

# So 58 and 1 are chosen to be declared at the starting.

# Changed dictionary to an array to quicken the solution
lowerCAmelCase    :     list[bool | None]					=						[None] * 10_00_00_00
lowerCAmelCase    :     List[str]					=						True
lowerCAmelCase    :     Union[str, Any]					=						False






def 			lowercase				(_A					):







       """simple docstring"""







       if CHAINS[number - 1] is not None:
              return CHAINS[number - 1]  # type: ignore

       _lowerCAmelCase    :							Any   			=       chain(next_number(_A					)					)
       _lowerCAmelCase    :							List[str]   			=       number_chain

       while number < 1_0_0_0_0_0_0_0:
              _lowerCAmelCase    :							Tuple   			=       number_chain
              number *= 1_0

       return number_chain






def 			lowercase				(_A = 1_0_0_0_0_0_0_0					):







       """simple docstring"""







       for i in range(1   ,						_A					):
              if CHAINS[i] is None:
                     chain(i + 1					)

       return CHAINS[:number].count(_A					)


if __name__ == "__main__":
       import doctest

       doctest.testmod()
       print(F'''{solution() = }''')

