


'''simple docstring'''
from collections import OrderedDict
from typing import Mapping

from packaging import version

from ...configuration_utils import PretrainedConfig
from ...onnx import OnnxConfig
from ...utils import logging


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

lowerCAmelCase   : int             =				{
    """sail/poolformer_s12""": """https://huggingface.co/sail/poolformer_s12/resolve/main/config.json""",
    # See all PoolFormer models at https://huggingface.co/models?filter=poolformer
}




class        _UpperCamelCase	(    SCREAMING_SNAKE_CASE):


				'''simple docstring'''


				_snake_case						       =				'''poolformer'''

				def __init__(     self							,      a_=3							,      a_=1_6							,      a_=1_6							,      a_=3							,      a_=4.0							,      a_=[2, 2, 6, 2]							,      a_=[6_4, 1_2_8, 3_2_0, 5_1_2]							,      a_=[7, 3, 3, 3]							,      a_=[4, 2, 2, 2]							,      a_=[2, 1, 1, 1]							,      a_=4							,      a_=0.0							,      a_="gelu"							,      a_=True							,      a_=1e-5							,      a_=0.02							,      **a_							,      )    ->  List[Any]:
					lowercase						:		Any   					=		num_channels
					lowercase						:		int   					=		patch_size
					lowercase						:		Tuple   					=		stride
					lowercase						:		List[str]   					=		padding
					lowercase						:		List[str]   					=		pool_size
					lowercase						:		str   					=		hidden_sizes
					lowercase						:		Optional[int]   					=		mlp_ratio
					lowercase						:		Union[str, Any]   					=		depths
					lowercase						:		Union[str, Any]   					=		patch_sizes
					lowercase						:		Optional[int]   					=		strides
					lowercase						:		Optional[Any]   					=		num_encoder_blocks
					lowercase						:		str   					=		drop_path_rate
					lowercase						:		str   					=		hidden_act
					lowercase						:		int   					=		use_layer_scale
					lowercase						:		int   					=		layer_scale_init_value
					lowercase						:		Any   					=		initializer_range
					super().__init__(**snake_case__							)




class        _UpperCamelCase	(    SCREAMING_SNAKE_CASE):


				'''simple docstring'''


				_snake_case						       =				version.parse('''1.11''')

				@property
				def 	a__		(     self							)    ->  List[str]:
					return OrderedDict(
					    [
					        ("pixel_values", {0: "batch", 1: "num_channels", 2: "height", 3: "width"}),
					    ]							)


				@property
				def 	a__		(     self							)    ->  Tuple:
					return 2e-3










"""simple docstring"""



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


_lowerCAmelCase	:	Optional[int]				=      logging.get_logger(__name__)

_lowerCAmelCase	:	Tuple				=      {
    """uw-madison/mra-base-512-4""": """https://huggingface.co/uw-madison/mra-base-512-4/resolve/main/config.json""",
}




class 			lowerCAmelCase__			(    __magic_name__   ):
   SCREAMING_SNAKE_CASE_    ='''mra'''
   def __init__(		self      :	Any							,			snake_case__      :	List[str]=5_0_2_6_5							,			snake_case__      :	Any=7_6_8							,			snake_case__      :	Union[str, Any]=1_2							,			snake_case__      :	Optional[Any]=1_2							,			snake_case__      :	Tuple=3_0_7_2							,			snake_case__      :	str="gelu"							,			snake_case__      :	Any=0.1							,			snake_case__      :	Tuple=0.1							,			snake_case__      :	Tuple=5_1_2							,			snake_case__      :	Union[str, Any]=1							,			snake_case__      :	List[Any]=0.02							,			snake_case__      :	str=1e-5							,			snake_case__      :	List[Any]="absolute"							,			snake_case__      :	str=4							,			snake_case__      :	List[str]="full"							,			snake_case__      :	Tuple=0							,			snake_case__      :	Any=0							,			snake_case__      :	Union[str, Any]=1							,			snake_case__      :	int=0							,			snake_case__      :	int=2							,			**snake_case__      :	List[Any]							,			):


        '''simple docstring'''
        super().__init__(pad_token_id=snake_case__							,			bos_token_id=snake_case__							,			eos_token_id=snake_case__							,			**snake_case__							)

        UpperCAmelCase__						:    List[Any]							=							vocab_size
        UpperCAmelCase__						:    str							=							max_position_embeddings
        UpperCAmelCase__						:    Any							=							hidden_size
        UpperCAmelCase__						:    Union[str, Any]							=							num_hidden_layers
        UpperCAmelCase__						:    str							=							num_attention_heads
        UpperCAmelCase__						:    int							=							intermediate_size
        UpperCAmelCase__						:    int							=							hidden_act
        UpperCAmelCase__						:    List[str]							=							hidden_dropout_prob
        UpperCAmelCase__						:    List[str]							=							attention_probs_dropout_prob
        UpperCAmelCase__						:    Any							=							initializer_range
        UpperCAmelCase__						:    Any							=							type_vocab_size
        UpperCAmelCase__						:    Dict							=							layer_norm_eps
        UpperCAmelCase__						:    Tuple							=							position_embedding_type
        UpperCAmelCase__						:    List[str]							=							block_per_row
        UpperCAmelCase__						:    Optional[Any]							=							approx_mode
        UpperCAmelCase__						:    Any							=							initial_prior_first_n_blocks
        UpperCAmelCase__						:    List[Any]							=							initial_prior_diagonal_n_blocks


