


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				:       int      =  logging.get_logger(__name__)

A				:       Dict      =  {
    '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      UpperCamelCase(	_a ):
					snake_case_		:					List[str]    					=						"""vit"""


					def __init__(    self						:		Optional[Any]  ,     SCREAMING_SNAKE_CASE						:		List[Any]=7_6_8  ,     SCREAMING_SNAKE_CASE						:		Any=1_2  ,     SCREAMING_SNAKE_CASE						:		Optional[Any]=1_2  ,     SCREAMING_SNAKE_CASE						:		Optional[Any]=3_0_7_2  ,     SCREAMING_SNAKE_CASE						:		Any="gelu"  ,     SCREAMING_SNAKE_CASE						:		int=0.0  ,     SCREAMING_SNAKE_CASE						:		Any=0.0  ,     SCREAMING_SNAKE_CASE						:		str=0.02  ,     SCREAMING_SNAKE_CASE						:		Dict=1e-1_2  ,     SCREAMING_SNAKE_CASE						:		Optional[int]=2_2_4  ,     SCREAMING_SNAKE_CASE						:		Dict=1_6  ,     SCREAMING_SNAKE_CASE						:		List[str]=3  ,     SCREAMING_SNAKE_CASE						:		List[Any]=True  ,     SCREAMING_SNAKE_CASE						:		int=1_6  ,     **SCREAMING_SNAKE_CASE						:		Optional[Any]  ,     )      ->						Union[str, Any]:




											'''simple docstring'''

											super().__init__(**SCREAMING_SNAKE_CASE    )

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






class      UpperCamelCase(	_a ):
					snake_case_		:					Dict    					=						version.parse("""1.11""" )


					@property
					def 				SCREAMING_SNAKE_CASE_	(    self						:		List[str]    )      ->						Mapping[str, Mapping[int, str]]:




											'''simple docstring'''

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






					@property
					def 				SCREAMING_SNAKE_CASE_	(    self						:		Dict    )      ->						float:




											'''simple docstring'''

											return 1e-4









from typing import TYPE_CHECKING

from ....utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available, is_vision_available


A				:       Optional[Any]      =  {'configuration_van': ['VAN_PRETRAINED_CONFIG_ARCHIVE_MAP', 'VanConfig']}


try:
	if not is_torch_available():
		raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
	pass
else:
	A				:       Optional[Any]      =  [
	    'VAN_PRETRAINED_MODEL_ARCHIVE_LIST',
	    'VanForImageClassification',
	    'VanModel',
	    'VanPreTrainedModel',
	]

if TYPE_CHECKING:
	from .configuration_van import VAN_PRETRAINED_CONFIG_ARCHIVE_MAP, VanConfig

	try:
		if not is_torch_available():
			raise OptionalDependencyNotAvailable()
	except OptionalDependencyNotAvailable:
		pass
	else:
		from .modeling_van import (
		    VAN_PRETRAINED_MODEL_ARCHIVE_LIST,
		    VanForImageClassification,
		    VanModel,
		    VanPreTrainedModel,
		)

else:
	import sys

	A				:       Union[str, Any]      =  _LazyModule(__name__, globals()['__file__'], _import_structure)





