






'''simple docstring'''







from collections import OrderedDict
from typing import Mapping

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


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

_A			:    str					  ={
    '''YituTech/conv-bert-base''': '''https://huggingface.co/YituTech/conv-bert-base/resolve/main/config.json''',
    '''YituTech/conv-bert-medium-small''': (
        '''https://huggingface.co/YituTech/conv-bert-medium-small/resolve/main/config.json'''
    ),
    '''YituTech/conv-bert-small''': '''https://huggingface.co/YituTech/conv-bert-small/resolve/main/config.json''',
    # See all ConvBERT models at https://huggingface.co/models?filter=convbert
}







class _lowercase			(       _lowercase	):
							a          = """convbert"""




							def __init__(							self:       Any    ,							UpperCamelCase__:       Dict=30_522    ,							UpperCamelCase__:       List[Any]=768    ,							UpperCamelCase__:       Union[str, Any]=12    ,							UpperCamelCase__:       str=12    ,							UpperCamelCase__:       int=3_072    ,							UpperCamelCase__:       Tuple="gelu"    ,							UpperCamelCase__:       Optional[Any]=0.1    ,							UpperCamelCase__:       List[Any]=0.1    ,							UpperCamelCase__:       Dict=512    ,							UpperCamelCase__:       List[str]=2    ,							UpperCamelCase__:       int=0.02    ,							UpperCamelCase__:       Dict=1e-12    ,							UpperCamelCase__:       List[str]=1    ,							UpperCamelCase__:       List[Any]=0    ,							UpperCamelCase__:       Tuple=2    ,							UpperCamelCase__:       int=768    ,							UpperCamelCase__:       Optional[int]=2    ,							UpperCamelCase__:       Tuple=9    ,							UpperCamelCase__:       Optional[int]=1    ,							UpperCamelCase__:       str=None    ,							**UpperCamelCase__:       int    ,							):
														super().__init__(
														    pad_token_id=UpperCamelCase__    ,							bos_token_id=UpperCamelCase__    ,							eos_token_id=UpperCamelCase__    ,							**UpperCamelCase__    ,							)

														lowerCamelCase__      :			Tuple 						= vocab_size
														lowerCamelCase__      :			List[Any] 						= hidden_size
														lowerCamelCase__      :			Dict 						= num_hidden_layers
														lowerCamelCase__      :			Optional[Any] 						= num_attention_heads
														lowerCamelCase__      :			List[str] 						= intermediate_size
														lowerCamelCase__      :			Tuple 						= hidden_act
														lowerCamelCase__      :			Optional[Any] 						= hidden_dropout_prob
														lowerCamelCase__      :			Union[str, Any] 						= attention_probs_dropout_prob
														lowerCamelCase__      :			str 						= max_position_embeddings
														lowerCamelCase__      :			List[str] 						= type_vocab_size
														lowerCamelCase__      :			Union[str, Any] 						= initializer_range
														lowerCamelCase__      :			Tuple 						= layer_norm_eps
														lowerCamelCase__      :			Dict 						= embedding_size
														lowerCamelCase__      :			Union[str, Any] 						= head_ratio
														lowerCamelCase__      :			Optional[int] 						= conv_kernel_size
														lowerCamelCase__      :			Any 						= num_groups
														lowerCamelCase__      :			int 						= classifier_dropout







class _lowercase			(       _lowercase	):




							@property
							def 	lowerCamelCase_       (							self:       str  ):
														if self.task == "multiple-choice":
																					lowerCamelCase__      :			int 						= {0: """batch""", 1: """choice""", 2: """sequence"""}
														else:
																					lowerCamelCase__      :			str 						= {0: """batch""", 1: """sequence"""}
														return OrderedDict(
														    [
														        ("""input_ids""", dynamic_axis),
														        ("""attention_mask""", dynamic_axis),
														        ("""token_type_ids""", dynamic_axis),
														    ]  )









'''simple docstring'''







_A			:    List[str]					  ='''0.21.0'''

from .accelerator import Accelerator
from .big_modeling import (
    cpu_offload,
    cpu_offload_with_hook,
    disk_offload,
    dispatch_model,
    init_empty_weights,
    init_on_device,
    load_checkpoint_and_dispatch,
)
from .data_loader import skip_first_batches
from .launchers import debug_launcher, notebook_launcher
from .state import PartialState
from .utils import (
    DeepSpeedPlugin,
    DistributedDataParallelKwargs,
    DistributedType,
    FullyShardedDataParallelPlugin,
    GradScalerKwargs,
    InitProcessGroupKwargs,
    find_executable_batch_size,
    infer_auto_device_map,
    is_rich_available,
    load_checkpoint_in_model,
    synchronize_rng_states,
)


if is_rich_available():
			from .utils import rich

