

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

_a:    Union[str, Any] 							=			{
    """facebook/deit-base-distilled-patch16-224""": (
        """https://huggingface.co/facebook/deit-base-patch16-224/resolve/main/config.json"""
    ),
    # See all DeiT models at https://huggingface.co/models?filter=deit
}

class 						__UpperCamelCase    (					lowercase						):
	SCREAMING_SNAKE_CASE__    				=     'deit'




	def __init__(		self	:						List[str]		,	lowerCAmelCase	:						Union[str, Any]=768		,	lowerCAmelCase	:						Optional[int]=12		,	lowerCAmelCase	:						Optional[Any]=12		,	lowerCAmelCase	:						Optional[int]=3_072		,	lowerCAmelCase	:						Dict="gelu"		,	lowerCAmelCase	:						str=0.0		,	lowerCAmelCase	:						Dict=0.0		,	lowerCAmelCase	:						str=0.02		,	lowerCAmelCase	:						Any=1e-12		,	lowerCAmelCase	:						Optional[int]=224		,	lowerCAmelCase	:						List[Any]=16		,	lowerCAmelCase	:						List[str]=3		,	lowerCAmelCase	:						Any=True		,	lowerCAmelCase	:						int=16		,	**lowerCAmelCase	:						Any		,	):


		'''simple docstring'''







		super().__init__(**_SCREAMING_SNAKE_CASE							)

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


class 						__UpperCamelCase    (					lowercase						):
	SCREAMING_SNAKE_CASE__    				=     version.parse('1.11'						)




	@property
	def       __A					(		self	:						Tuple							):


		'''simple docstring'''







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




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


		'''simple docstring'''







		return 1e-4


from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_torch_available,
)


_a:    List[str] 							=			{
    """configuration_encodec""": [
        """ENCODEC_PRETRAINED_CONFIG_ARCHIVE_MAP""",
        """EncodecConfig""",
    ],
    """feature_extraction_encodec""": ["""EncodecFeatureExtractor"""],
}

try:
				if not is_torch_available():
								raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
				pass
else:
				_a:    List[Any] 							=			[
				    """ENCODEC_PRETRAINED_MODEL_ARCHIVE_LIST""",
				    """EncodecModel""",
				    """EncodecPreTrainedModel""",
				]

if TYPE_CHECKING:
				from .configuration_encodec import (
				    ENCODEC_PRETRAINED_CONFIG_ARCHIVE_MAP,
				    EncodecConfig,
				)
				from .feature_extraction_encodec import EncodecFeatureExtractor

				try:
								if not is_torch_available():
												raise OptionalDependencyNotAvailable()
				except OptionalDependencyNotAvailable:
								pass
				else:
								from .modeling_encodec import (
								    ENCODEC_PRETRAINED_MODEL_ARCHIVE_LIST,
								    EncodecModel,
								    EncodecPreTrainedModel,
								)

else:
				import sys

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