





'''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


a        =						logging.get_logger(__name__)

a        =						{
    "google/vit-base-patch16-224": "https://huggingface.co/vit-base-patch16-224/resolve/main/config.json",
    # See all ViT models at https://huggingface.co/models?filter=vit
}







class __a (   _snake_case			):

   '''simple docstring'''





   __UpperCamelCase   : str	      =	'vit'





   def __init__(					self				:			Dict				,lowerCamelCase				:			Tuple=768				,lowerCamelCase				:			Any=12				,lowerCamelCase				:			Optional[int]=12				,lowerCamelCase				:			List[str]=3072				,lowerCamelCase				:			Tuple="gelu"				,lowerCamelCase				:			Tuple=0.0				,lowerCamelCase				:			int=0.0				,lowerCamelCase				:			Optional[int]=0.02				,lowerCamelCase				:			int=1E-1_2				,lowerCamelCase				:			Optional[Any]=224				,lowerCamelCase				:			int=16				,lowerCamelCase				:			Optional[int]=3				,lowerCamelCase				:			Tuple=True				,lowerCamelCase				:			List[Any]=16				,**lowerCamelCase				:			Any				,):

      '''simple docstring'''

      super().__init__(**lowerCamelCase    )

      __SCREAMING_SNAKE_CASE      							=       hidden_size
      __SCREAMING_SNAKE_CASE      							=       num_hidden_layers
      __SCREAMING_SNAKE_CASE      							=       num_attention_heads
      __SCREAMING_SNAKE_CASE      							=       intermediate_size
      __SCREAMING_SNAKE_CASE      							=       hidden_act
      __SCREAMING_SNAKE_CASE      							=       hidden_dropout_prob
      __SCREAMING_SNAKE_CASE      							=       attention_probs_dropout_prob
      __SCREAMING_SNAKE_CASE      							=       initializer_range
      __SCREAMING_SNAKE_CASE      							=       layer_norm_eps
      __SCREAMING_SNAKE_CASE      							=       image_size
      __SCREAMING_SNAKE_CASE      							=       patch_size
      __SCREAMING_SNAKE_CASE      							=       num_channels
      __SCREAMING_SNAKE_CASE      							=       qkv_bias
      __SCREAMING_SNAKE_CASE      							=       encoder_stride







class __a (   _snake_case			):

   '''simple docstring'''





   __UpperCamelCase   : Union[str, Any]	      =	version.parse('1.11'			)





   @property
   def      UpperCAmelCase__     (					self				:			List[Any]    ):

      '''simple docstring'''

      return OrderedDict(
          [
              ("""pixel_values""", {0: """batch""", 1: """num_channels""", 2: """height""", 3: """width"""}),
          ]    )





   @property
   def      UpperCAmelCase__     (					self				:			Union[str, Any]    ):

      '''simple docstring'''

      return 1E-4












'''simple docstring'''

from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available


a        =						{"configuration_sew": ["SEW_PRETRAINED_CONFIG_ARCHIVE_MAP", "SEWConfig"]}

try:
    if not is_torch_available():
        raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
    pass
else:
    a        =						[
        "SEW_PRETRAINED_MODEL_ARCHIVE_LIST",
        "SEWForCTC",
        "SEWForSequenceClassification",
        "SEWModel",
        "SEWPreTrainedModel",
    ]

if TYPE_CHECKING:
    from .configuration_sew import SEW_PRETRAINED_CONFIG_ARCHIVE_MAP, SEWConfig

    try:
        if not is_torch_available():
            raise OptionalDependencyNotAvailable()
    except OptionalDependencyNotAvailable:
        pass
    else:
        from .modeling_sew import (
            SEW_PRETRAINED_MODEL_ARCHIVE_LIST,
            SEWForCTC,
            SEWForSequenceClassification,
            SEWModel,
            SEWPreTrainedModel,
        )


else:
    import sys

    a        =						_LazyModule(__name__, globals()["__file__"], _import_structure, module_spec=__spec__)





