





'''simple docstring'''




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


lowercase__   :				Union[str, Any]      =   logging.get_logger(__name__)

lowercase__   :				Dict      =   {
    """google/canine-s""": """https://huggingface.co/google/canine-s/resolve/main/config.json""",
    # See all CANINE models at https://huggingface.co/models?filter=canine
}


class 			SCREAMING_SNAKE_CASE   (lowerCAmelCase_							):
     lowerCAmelCase		      =	"""canine"""


     def __init__(						self						,     _UpperCAmelCase=768						,     _UpperCAmelCase=12						,     _UpperCAmelCase=12						,     _UpperCAmelCase=3072						,     _UpperCAmelCase="gelu"						,     _UpperCAmelCase=0.1						,     _UpperCAmelCase=0.1						,     _UpperCAmelCase=1_6384						,     _UpperCAmelCase=16						,     _UpperCAmelCase=0.02						,     _UpperCAmelCase=1e-1_2						,     _UpperCAmelCase=0						,     _UpperCAmelCase=0Xe_0_0_0						,     _UpperCAmelCase=0Xe_0_0_1						,     _UpperCAmelCase=4						,     _UpperCAmelCase=4						,     _UpperCAmelCase=8						,     _UpperCAmelCase=1_6384						,     _UpperCAmelCase=128						,     **_UpperCAmelCase						,     ):

          '''simple docstring'''






          super().__init__(pad_token_id=__SCREAMING_SNAKE_CASE						,     bos_token_id=__SCREAMING_SNAKE_CASE						,     eos_token_id=__SCREAMING_SNAKE_CASE						,     **__SCREAMING_SNAKE_CASE)

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

          # Character config:
          __A						:			Optional[Any]								=	downsampling_rate
          __A						:			Optional[Any]								=	upsampling_kernel_size
          __A						:			int								=	num_hash_functions
          __A						:			Optional[Any]								=	num_hash_buckets
          __A						:			str								=	local_transformer_stride








'''simple docstring'''




import math






def 	_lowerCAmelCase      (  __snake_case  :			int      )					->					int:

     if not isinstance(__snake_case			,							__snake_case      ):
          __A						:			List[Any]								=	f'Input value of [number={number}] must be an integer'
          raise TypeError(__snake_case      )

     if number < 1:
          __A						:			Union[str, Any]								=	f'Input value of [number={number}] must be > 0'
          raise ValueError(__snake_case      )
     elif number == 1:
          return 3
     elif number == 2:
          return 5
     else:
          __A						:			Optional[Any]								=	int(math.log(number // 3			,							2      )      ) + 2

          __A						:			Union[str, Any]								=	[3, 5]
          __A						:			List[Any]								=	2
          __A						:			Optional[Any]								=	3
          for block in range(1			,							__snake_case      ):
               for _ in range(__snake_case      ):
                    proth_list.append(2 ** (block + 1) + proth_list[proth_index - 1]      )
                    proth_index += 1
               increment *= 2

     return proth_list[number - 1]


if __name__ == "__main__":
  import doctest

  doctest.testmod()

  for number in range(11):
    lowercase__   :				str      =   0
    try:
      lowercase__   :				List[str]      =   proth(number)
    except ValueError:
      print(f"""ValueError: there is no {number}th Proth number""")
      continue

    print(f"""The {number}th Proth number: {value}""")