






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


a 			=							logging.get_logger(__name__)

a 			=							{
    'facebook/opt-125m': 'https://huggingface.co/facebook/opt-125m/blob/main/config.json',
    'facebook/opt-350m': 'https://huggingface.co/facebook/opt-350m/blob/main/config.json',
    'facebook/opt-1.3b': 'https://huggingface.co/facebook/opt-1.3b/blob/main/config.json',
    'facebook/opt-2.7b': 'https://huggingface.co/facebook/opt-2.7b/blob/main/config.json',
    'facebook/opt-6.7b': 'https://huggingface.co/facebook/opt-6.7b/blob/main/config.json',
    'facebook/opt-13b': 'https://huggingface.co/facebook/opt-13b/blob/main/config.json',
}
class 							__snake_case(       __UpperCamelCase   ):
 lowercase			:							Any		   =		'''opt'''
 lowercase			:							Optional[int]		   =		['''past_key_values''']



 def __init__(						self : str			,		UpperCAmelCase__ : str=50_272			,		UpperCAmelCase__ : Dict=768			,		UpperCAmelCase__ : List[str]=12			,		UpperCAmelCase__ : Union[str, Any]=3_072			,		UpperCAmelCase__ : Union[str, Any]=2_048			,		UpperCAmelCase__ : Tuple=True			,		UpperCAmelCase__ : Any=False			,		UpperCAmelCase__ : Tuple=None			,		UpperCAmelCase__ : List[Any]=0.1			,		UpperCAmelCase__ : int=0.0			,		UpperCAmelCase__ : List[Any]=12			,		UpperCAmelCase__ : Any="relu"			,		UpperCAmelCase__ : Dict=0.0			,		UpperCAmelCase__ : Optional[int]=0.02			,		UpperCAmelCase__ : List[Any]=True			,		UpperCAmelCase__ : int=1			,		UpperCAmelCase__ : str=2			,		UpperCAmelCase__ : Optional[Any]=2			,		UpperCAmelCase__ : List[str]=True			,		UpperCAmelCase__ : str=True			,		**UpperCAmelCase__ : List[str]			,		):

    """simple docstring"""






    super().__init__(
        pad_token_id=UpperCAmelCase__			,		bos_token_id=UpperCAmelCase__			,		eos_token_id=UpperCAmelCase__			,		**UpperCAmelCase__			,		)
    lowercase__    :						Optional[int]       =			vocab_size
    lowercase__    :						str       =			max_position_embeddings
    lowercase__    :						Any       =			num_attention_heads
    lowercase__    :						List[str]       =			word_embed_proj_dim if word_embed_proj_dim is not None else hidden_size
    lowercase__    :						Dict       =			ffn_dim
    lowercase__    :						Optional[int]       =			hidden_size
    lowercase__    :						Optional[Any]       =			num_hidden_layers
    lowercase__    :						List[str]       =			dropout
    lowercase__    :						Any       =			attention_dropout
    lowercase__    :						Union[str, Any]       =			activation_function
    lowercase__    :						Optional[int]       =			init_std
    lowercase__    :						Union[str, Any]       =			layerdrop
    lowercase__    :						List[Any]       =			use_cache
    lowercase__    :						str       =			do_layer_norm_before
    # We keep these variables at `True` for backward compatibility.
    lowercase__    :						List[str]       =			enable_bias
    lowercase__    :						List[Any]       =			layer_norm_elementwise_affine

    # Note that the only purpose of `_remove_final_layer_norm` is to keep backward compatibility
    # with checkpoints that have been fine-tuned before transformers v4.20.1
    # see https://github.com/facebookresearch/metaseq/pull/164
    lowercase__    :						Union[str, Any]       =			_remove_final_layer_norm










def    a__    (	A       ):
   return int(A       ) if x - int(A       ) >= 0 else int(A       ) - 1


if __name__ == "__main__":
 import doctest

 doctest.testmod()


