
"""simple docstring"""






from collections import OrderedDict
from typing import Mapping

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


lowerCamelCase__ :       int						     =			logging.get_logger(__name__)

lowerCamelCase__ :       List[Any]						     =			{
    "distilbert-base-uncased": "https://huggingface.co/distilbert-base-uncased/resolve/main/config.json",
    "distilbert-base-uncased-distilled-squad": (
        "https://huggingface.co/distilbert-base-uncased-distilled-squad/resolve/main/config.json"
    ),
    "distilbert-base-cased": "https://huggingface.co/distilbert-base-cased/resolve/main/config.json",
    "distilbert-base-cased-distilled-squad": (
        "https://huggingface.co/distilbert-base-cased-distilled-squad/resolve/main/config.json"
    ),
    "distilbert-base-german-cased": "https://huggingface.co/distilbert-base-german-cased/resolve/main/config.json",
    "distilbert-base-multilingual-cased": (
        "https://huggingface.co/distilbert-base-multilingual-cased/resolve/main/config.json"
    ),
    "distilbert-base-uncased-finetuned-sst-2-english": (
        "https://huggingface.co/distilbert-base-uncased-finetuned-sst-2-english/resolve/main/config.json"
    ),
}




class 				lowercase__(				_UpperCAmelCase   ):
	'''simple docstring'''

	UpperCamelCase				=  """distilbert"""
	UpperCamelCase				=  {
	    """hidden_size""": """dim""",
	    """num_attention_heads""": """n_heads""",
	    """num_hidden_layers""": """n_layers""",
	}





	def __init__(						self    :Any		, lowerCamelCase_    :Tuple=3_05_22		, lowerCamelCase_    :Optional[Any]=5_12		, lowerCamelCase_    :Dict=False		, lowerCamelCase_    :str=6		, lowerCamelCase_    :Tuple=12		, lowerCamelCase_    :int=7_68		, lowerCamelCase_    :Optional[Any]=4 * 7_68		, lowerCamelCase_    :List[Any]=0.1		, lowerCamelCase_    :Optional[int]=0.1		, lowerCamelCase_    :int="gelu"		, lowerCamelCase_    :Union[str, Any]=0.0_2		, lowerCamelCase_    :List[str]=0.1		, lowerCamelCase_    :Dict=0.2		, lowerCamelCase_    :Union[str, Any]=0		, **lowerCamelCase_    :List[str]		, )							->			List[Any]:







			'''simple docstring'''




			SCREAMING_SNAKE_CASE       :     Dict				= vocab_size
			SCREAMING_SNAKE_CASE       :     Optional[int]				= max_position_embeddings
			SCREAMING_SNAKE_CASE       :     List[str]				= sinusoidal_pos_embds
			SCREAMING_SNAKE_CASE       :     List[Any]				= n_layers
			SCREAMING_SNAKE_CASE       :     Dict				= n_heads
			SCREAMING_SNAKE_CASE       :     List[Any]				= dim
			SCREAMING_SNAKE_CASE       :     str				= hidden_dim
			SCREAMING_SNAKE_CASE       :     List[str]				= dropout
			SCREAMING_SNAKE_CASE       :     Dict				= attention_dropout
			SCREAMING_SNAKE_CASE       :     Tuple				= activation
			SCREAMING_SNAKE_CASE       :     Tuple				= initializer_range
			SCREAMING_SNAKE_CASE       :     Optional[int]				= qa_dropout
			SCREAMING_SNAKE_CASE       :     str				= seq_classif_dropout
			super().__init__(**lowerCamelCase_		, pad_token_id=lowerCamelCase_					)





class 				lowercase__(				_UpperCAmelCase   ):
	'''simple docstring'''

	@property
	def   __lowerCAmelCase (						self    :Tuple					)							->			Mapping[str, Mapping[int, str]]:







			'''simple docstring'''




			if self.task == "multiple-choice":
					SCREAMING_SNAKE_CASE       :     Union[str, Any]				= {0: '''batch''', 1: '''choice''', 2: '''sequence'''}
			else:
					SCREAMING_SNAKE_CASE       :     Tuple				= {0: '''batch''', 1: '''sequence'''}
			return OrderedDict(
			    [
			        ('''input_ids''', dynamic_axis),
			        ('''attention_mask''', dynamic_axis),
			    ]					)







"""simple docstring"""






from typing import TYPE_CHECKING

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


lowerCamelCase__ :       Tuple						     =			{
    "configuration_mctct": ["MCTCT_PRETRAINED_CONFIG_ARCHIVE_MAP", "MCTCTConfig"],
    "feature_extraction_mctct": ["MCTCTFeatureExtractor"],
    "processing_mctct": ["MCTCTProcessor"],
}


try:
					if not is_torch_available():
										raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
					pass
else:
					lowerCamelCase__ :       Union[str, Any]						     =			[
					    "MCTCT_PRETRAINED_MODEL_ARCHIVE_LIST",
					    "MCTCTForCTC",
					    "MCTCTModel",
					    "MCTCTPreTrainedModel",
					]


if TYPE_CHECKING:
					from .configuration_mctct import MCTCT_PRETRAINED_CONFIG_ARCHIVE_MAP, MCTCTConfig
					from .feature_extraction_mctct import MCTCTFeatureExtractor
					from .processing_mctct import MCTCTProcessor

					try:
										if not is_torch_available():
															raise OptionalDependencyNotAvailable()
					except OptionalDependencyNotAvailable:
										pass
					else:
										from .modeling_mctct import MCTCT_PRETRAINED_MODEL_ARCHIVE_LIST, MCTCTForCTC, MCTCTModel, MCTCTPreTrainedModel

else:
					import sys

					lowerCamelCase__ :       Tuple						     =			_LazyModule(__name__, globals()["__file__"], _import_structure, module_spec=__spec__)





