
'''simple docstring'''







import warnings

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


_lowercase			:  str   							=	logging.get_logger(__name__)

_lowercase			:  Tuple   							=	{
    'RUCAIBox/mvp': 'https://huggingface.co/RUCAIBox/mvp/resolve/main/config.json',
}






class 			lowerCAmelCase__       (  lowerCAmelCase__					):
					lowerCAmelCase_					       =					"mvp"
					lowerCAmelCase_					       =					["past_key_values"]
					lowerCAmelCase_					       =					{"num_attention_heads": "encoder_attention_heads", "hidden_size": "d_model"}






					def __init__(       self    ,							__SCREAMING_SNAKE_CASE=5_02_67    ,							__SCREAMING_SNAKE_CASE=10_24    ,							__SCREAMING_SNAKE_CASE=12    ,							__SCREAMING_SNAKE_CASE=40_96    ,							__SCREAMING_SNAKE_CASE=16    ,							__SCREAMING_SNAKE_CASE=12    ,							__SCREAMING_SNAKE_CASE=40_96    ,							__SCREAMING_SNAKE_CASE=16    ,							__SCREAMING_SNAKE_CASE=0.0    ,							__SCREAMING_SNAKE_CASE=0.0    ,							__SCREAMING_SNAKE_CASE="gelu"    ,							__SCREAMING_SNAKE_CASE=10_24    ,							__SCREAMING_SNAKE_CASE=0.1    ,							__SCREAMING_SNAKE_CASE=0.0    ,							__SCREAMING_SNAKE_CASE=0.0    ,							__SCREAMING_SNAKE_CASE=0.02    ,							__SCREAMING_SNAKE_CASE=0.0    ,							__SCREAMING_SNAKE_CASE=False    ,							__SCREAMING_SNAKE_CASE=True    ,							__SCREAMING_SNAKE_CASE=1    ,							__SCREAMING_SNAKE_CASE=0    ,							__SCREAMING_SNAKE_CASE=2    ,							__SCREAMING_SNAKE_CASE=True    ,							__SCREAMING_SNAKE_CASE=2    ,							__SCREAMING_SNAKE_CASE=2    ,							__SCREAMING_SNAKE_CASE=False    ,							__SCREAMING_SNAKE_CASE=1_00    ,							__SCREAMING_SNAKE_CASE=8_00    ,							**__SCREAMING_SNAKE_CASE    ,							):


											"""simple docstring"""





											lowercase_     :					Optional[Any]													=	vocab_size
											lowercase_     :					List[Any]													=	max_position_embeddings
											lowercase_     :					int													=	d_model
											lowercase_     :					Optional[Any]													=	encoder_ffn_dim
											lowercase_     :					List[Any]													=	encoder_layers
											lowercase_     :					Any													=	encoder_attention_heads
											lowercase_     :					Optional[int]													=	decoder_ffn_dim
											lowercase_     :					Optional[int]													=	decoder_layers
											lowercase_     :					List[Any]													=	decoder_attention_heads
											lowercase_     :					str													=	dropout
											lowercase_     :					List[Any]													=	attention_dropout
											lowercase_     :					Optional[Any]													=	activation_dropout
											lowercase_     :					List[Any]													=	activation_function
											lowercase_     :					Optional[int]													=	init_std
											lowercase_     :					Optional[Any]													=	encoder_layerdrop
											lowercase_     :					List[Any]													=	decoder_layerdrop
											lowercase_     :					Optional[Any]													=	classifier_dropout
											lowercase_     :					str													=	use_cache
											lowercase_     :					Any													=	encoder_layers
											lowercase_     :					List[str]													=	scale_embedding  # scale factor will be sqrt(d_model) if True
											lowercase_     :					Optional[Any]													=	use_prompt
											lowercase_     :					Optional[Any]													=	prompt_length
											lowercase_     :					List[str]													=	prompt_mid_dim

											super().__init__(
											    pad_token_id=_SCREAMING_SNAKE_CASE    ,							bos_token_id=_SCREAMING_SNAKE_CASE    ,							eos_token_id=_SCREAMING_SNAKE_CASE    ,							is_encoder_decoder=_SCREAMING_SNAKE_CASE    ,							decoder_start_token_id=_SCREAMING_SNAKE_CASE    ,							forced_eos_token_id=_SCREAMING_SNAKE_CASE    ,							**_SCREAMING_SNAKE_CASE    ,							)

											if self.forced_bos_token_id is None and kwargs.get('''force_bos_token_to_be_generated'''    ,							_SCREAMING_SNAKE_CASE		):
																	lowercase_     :					List[str]													=	self.bos_token_id
																	warnings.warn(
																	    F'''Please make sure the config includes `forced_bos_token_id={self.bos_token_id}` in future versions. '''
																	    '''The config can simply be saved and uploaded again to be fixed.'''		)






'''simple docstring'''







from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available


_lowercase			:  Tuple   							=	{"configuration_vit_msn": ["VIT_MSN_PRETRAINED_CONFIG_ARCHIVE_MAP", "ViTMSNConfig"]}

try:
							if not is_torch_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							_lowercase			:  str   							=	[
							    "VIT_MSN_PRETRAINED_MODEL_ARCHIVE_LIST",
							    "ViTMSNModel",
							    "ViTMSNForImageClassification",
							    "ViTMSNPreTrainedModel",
							]

if TYPE_CHECKING:
							from .configuration_vit_msn import VIT_MSN_PRETRAINED_CONFIG_ARCHIVE_MAP, ViTMSNConfig

							try:
														if not is_torch_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .modeling_vit_msn import (
														    VIT_MSN_PRETRAINED_MODEL_ARCHIVE_LIST,
														    ViTMSNForImageClassification,
														    ViTMSNModel,
														    ViTMSNPreTrainedModel,
														)

else:
							import sys

							_lowercase			:  int   							=	_LazyModule(__name__, globals()["__file__"], _import_structure, module_spec=__spec__)



