

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


SCREAMING_SNAKE_CASE		:List[str]				  =    logging.get_logger(__name__)

SCREAMING_SNAKE_CASE		:str				  =    {
    """MBZUAI/swiftformer-xs""": """https://huggingface.co/MBZUAI/swiftformer-xs/resolve/main/config.json""",
}






class 	__magic_name__				(       snake_case							):
     UpperCamelCase_  :Any								=			"""swiftformer"""






     def __init__(							self		,	_lowercase=3		,	_lowercase=[3, 3, 6, 4]		,	_lowercase=[48, 56, 112, 220]		,	_lowercase=4		,	_lowercase=[True, True, True, True]		,	_lowercase="gelu"		,	_lowercase=3		,	_lowercase=2		,	_lowercase=1		,	_lowercase=0.0		,	_lowercase=True		,	_lowercase=1e-5		,	_lowercase=1e-5		,	**_lowercase		,	)->    str:
         super().__init__(**_lowercase  )
         UpperCamelCase_      =	num_channels
         UpperCamelCase_      =	depths
         UpperCamelCase_      =	embed_dims
         UpperCamelCase_      =	mlp_ratio
         UpperCamelCase_      =	downsamples
         UpperCamelCase_      =	hidden_act
         UpperCamelCase_      =	down_patch_size
         UpperCamelCase_      =	down_stride
         UpperCamelCase_      =	down_pad
         UpperCamelCase_      =	drop_path_rate
         UpperCamelCase_      =	use_layer_scale
         UpperCamelCase_      =	layer_scale_init_value
         UpperCamelCase_      =	batch_norm_eps






class 	__magic_name__				(       snake_case							):
     UpperCamelCase_  :Union[str, Any]								=			version.parse("""1.11"""							)






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






     @property
     def   UpperCAmelCase_							(							self  )->    float:
         return 1e-4



def  lowerCAmelCase(			SCREAMING_SNAKE_CASE_ ,	SCREAMING_SNAKE_CASE_ ,	SCREAMING_SNAKE_CASE_ )->	str:



    """simple docstring"""






    if power < 0:
        return -1
    base %= mod
    UpperCamelCase_      =	1

    while power > 0:
        if power & 1:
            UpperCamelCase_      =	(result * base) % mod
        UpperCamelCase_      =	power >> 1
        UpperCamelCase_      =	(base * base) % mod

    return result




def  lowerCAmelCase(			)->	Tuple:



    """simple docstring"""






    print(modular_exponential(3 ,	2_0_0 ,	1_3 ) )


if __name__ == "__main__":
 import doctest

 doctest.testmod()

 main()
