






'''simple docstring'''
def  _a(  UpperCamelCase__				:						int,	UpperCamelCase__				:						int							):




      '''simple docstring'''






      if number < 0 or shift_amount < 0:
            raise ValueError('''both inputs must be positive integers'''							)

      SCREAMING_SNAKE_CASE__     :				Tuple									=str(bin(UpperCamelCase__							)							)
      binary_number += "0" * shift_amount
      return binary_number





def  _a(  UpperCamelCase__				:						int,	UpperCamelCase__				:						int							):




      '''simple docstring'''






      if number < 0 or shift_amount < 0:
            raise ValueError('''both inputs must be positive integers'''							)

      SCREAMING_SNAKE_CASE__     :				str									=str(bin(UpperCamelCase__							)							)[2:]
      if shift_amount >= len(UpperCamelCase__							):
            return "0b0"
      SCREAMING_SNAKE_CASE__     :				List[str]									=binary_number[: len(UpperCamelCase__							) - shift_amount]
      return "0b" + shifted_binary_number





def  _a(  UpperCamelCase__				:						int,	UpperCamelCase__				:						int							):




      '''simple docstring'''






      if number >= 0:  # Get binary representation of positive number
            SCREAMING_SNAKE_CASE__     :				int									='''0''' + str(bin(UpperCamelCase__							)							).strip('''-'''							)[2:]
      else:  # Get binary (2's complement) representation of negative number
            SCREAMING_SNAKE_CASE__     :				List[str]									=len(bin(UpperCamelCase__							)[3:]							)  # Find 2's complement of number
            SCREAMING_SNAKE_CASE__     :				List[Any]									=bin(abs(UpperCamelCase__							) - (1 << binary_number_length)							)[3:]
            SCREAMING_SNAKE_CASE__     :				Union[str, Any]									=(
                '''1''' + '''0''' * (binary_number_length - len(UpperCamelCase__							)) + binary_number
            )

      if shift_amount >= len(UpperCamelCase__							):
            return "0b" + binary_number[0] * len(UpperCamelCase__							)
      return (
          "0b"
          + binary_number[0] * shift_amount
          + binary_number[: len(UpperCamelCase__							) - shift_amount]
      )


if __name__ == "__main__":
  import doctest

  doctest.testmod()







'''simple docstring'''
from ...configuration_utils import PretrainedConfig
from ...utils import logging


a_					= logging.get_logger(__name__)

a_					= {
    'bigcode/gpt_bigcode-santacoder': 'https://huggingface.co/bigcode/gpt_bigcode-santacoder/resolve/main/config.json',
}






class      __SCREAMING_SNAKE_CASE      (			lowerCamelCase				):
 snake_case_  							=							"""gpt_bigcode"""
 snake_case_  							=							["""past_key_values"""]
 snake_case_  							=							{
     """hidden_size""": """n_embd""",
     """max_position_embeddings""": """n_positions""",
     """num_attention_heads""": """n_head""",
     """num_hidden_layers""": """n_layer""",
 }




 def __init__(      self	:							Any					,      __lowercase	:							Any=5_02_57					,      __lowercase	:							int=10_24					,      __lowercase	:							List[str]=7_68					,      __lowercase	:							Optional[int]=12					,      __lowercase	:							Dict=12					,      __lowercase	:							List[str]=None					,      __lowercase	:							int="gelu_pytorch_tanh"					,      __lowercase	:							Union[str, Any]=0.1					,      __lowercase	:							Optional[int]=0.1					,      __lowercase	:							Optional[int]=0.1					,      __lowercase	:							Optional[Any]=1e-5					,      __lowercase	:							List[str]=0.02					,      __lowercase	:							Tuple=True					,      __lowercase	:							Optional[Any]=True					,      __lowercase	:							Union[str, Any]=5_02_56					,      __lowercase	:							List[Any]=5_02_56					,      __lowercase	:							Union[str, Any]=True					,      __lowercase	:							List[str]=True					,      __lowercase	:							Dict=True					,      **__lowercase	:							List[Any]					,      )	->						Optional[int]:
       SCREAMING_SNAKE_CASE__     :				Union[str, Any]									=vocab_size
       SCREAMING_SNAKE_CASE__     :				Union[str, Any]									=n_positions
       SCREAMING_SNAKE_CASE__     :				Dict									=n_embd
       SCREAMING_SNAKE_CASE__     :				Dict									=n_layer
       SCREAMING_SNAKE_CASE__     :				Union[str, Any]									=n_head
       SCREAMING_SNAKE_CASE__     :				List[str]									=n_inner
       SCREAMING_SNAKE_CASE__     :				List[str]									=activation_function
       SCREAMING_SNAKE_CASE__     :				List[Any]									=resid_pdrop
       SCREAMING_SNAKE_CASE__     :				List[Any]									=embd_pdrop
       SCREAMING_SNAKE_CASE__     :				List[str]									=attn_pdrop
       SCREAMING_SNAKE_CASE__     :				Dict									=layer_norm_epsilon
       SCREAMING_SNAKE_CASE__     :				List[str]									=initializer_range
       SCREAMING_SNAKE_CASE__     :				List[Any]									=scale_attn_weights
       SCREAMING_SNAKE_CASE__     :				Union[str, Any]									=use_cache
       SCREAMING_SNAKE_CASE__     :				Dict									=attention_softmax_in_fpaa
       SCREAMING_SNAKE_CASE__     :				int									=scale_attention_softmax_in_fpaa
       SCREAMING_SNAKE_CASE__     :				Dict									=multi_query

       SCREAMING_SNAKE_CASE__     :				Optional[Any]									=bos_token_id
       SCREAMING_SNAKE_CASE__     :				Optional[Any]									=eos_token_id

       super().__init__(bos_token_id=__lowercase					,      eos_token_id=__lowercase					,      **__lowercase      )