



"""simple docstring"""




from ....configuration_utils import PretrainedConfig
from ....utils import logging


_lowerCAmelCase							:   Tuple				=				logging.get_logger(__name__)

_lowerCAmelCase							:   Dict				=				{
    "speechbrain/m-ctc-t-large": "https://huggingface.co/speechbrain/m-ctc-t-large/resolve/main/config.json",
    # See all M-CTC-T models at https://huggingface.co/models?filter=mctct
}






class       UpperCAmelCase_    (							_UpperCamelCase		):
      __SCREAMING_SNAKE_CASE		:  str						=					'mctct'



      def __init__(	self	:      Union[str, Any]	,      A	:      int=8_0_6_5	,      A	:      Tuple=1_5_3_6	,      A	:      str=3_6	,      A	:      Optional[Any]=6_1_4_4	,      A	:      int=4	,      A	:      int=3_8_4	,      A	:      Optional[int]=9_2_0	,      A	:      int=1e-5	,      A	:      Tuple=0.3	,      A	:      List[Any]="relu"	,      A	:      Tuple=0.02	,      A	:      int=0.3	,      A	:      Optional[Any]=0.3	,      A	:      List[Any]=1	,      A	:      Optional[Any]=0	,      A	:      Optional[int]=2	,      A	:      int=1	,      A	:      Optional[int]=0.3	,      A	:      Optional[Any]=1	,      A	:      Union[str, Any]=(7,)	,      A	:      int=(3,)	,      A	:      Optional[Any]=8_0	,      A	:      Any=1	,      A	:      List[Any]=None	,      A	:      Optional[Any]="sum"	,      A	:      str=False	,      **A	:      List[str]	,      ):
           super().__init__(**A	,      pad_token_id=A	,      bos_token_id=A	,      eos_token_id=A		)
           _UpperCAmelCase     :      List[str]														=       vocab_size
           _UpperCAmelCase     :      Dict														=       hidden_size
           _UpperCAmelCase     :      int														=       num_hidden_layers
           _UpperCAmelCase     :      Optional[int]														=       intermediate_size
           _UpperCAmelCase     :      Optional[Any]														=       num_attention_heads
           _UpperCAmelCase     :      Optional[Any]														=       attention_head_dim
           _UpperCAmelCase     :      Any														=       max_position_embeddings
           _UpperCAmelCase     :      Tuple														=       layer_norm_eps
           _UpperCAmelCase     :      List[str]														=       layerdrop
           _UpperCAmelCase     :      List[str]														=       hidden_act
           _UpperCAmelCase     :      Union[str, Any]														=       initializer_range
           _UpperCAmelCase     :      Dict														=       hidden_dropout_prob
           _UpperCAmelCase     :      Any														=       attention_probs_dropout_prob
           _UpperCAmelCase     :      List[str]														=       pad_token_id
           _UpperCAmelCase     :      str														=       bos_token_id
           _UpperCAmelCase     :      Union[str, Any]														=       eos_token_id
           _UpperCAmelCase     :      Optional[int]														=       conv_glu_dim
           _UpperCAmelCase     :      str														=       conv_dropout
           _UpperCAmelCase     :      int														=       num_conv_layers
           _UpperCAmelCase     :      Tuple														=       input_feat_per_channel
           _UpperCAmelCase     :      List[Any]														=       input_channels
           _UpperCAmelCase     :      int														=       conv_channels
           _UpperCAmelCase     :      Any														=       ctc_loss_reduction
           _UpperCAmelCase     :      Dict														=       ctc_zero_infinity

           # prevents config testing fail with exporting to json
           _UpperCAmelCase     :      Tuple														=       list(A		)
           _UpperCAmelCase     :      Optional[Any]														=       list(A		)

           if len(self.conv_kernel		) != self.num_conv_layers:
                raise ValueError(
                    "Configuration for convolutional module is incorrect. "
                    "It is required that `len(config.conv_kernel)` == `config.num_conv_layers` "
                    f'but is `len(config.conv_kernel) = {len(self.conv_kernel		)}`, '
                    f'`config.num_conv_layers = {self.num_conv_layers}`.'		)





"""simple docstring"""




from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available


_lowerCAmelCase							:   List[Any]				=				{
    "configuration_lilt": ["LILT_PRETRAINED_CONFIG_ARCHIVE_MAP", "LiltConfig"],
}

try:
 if not is_torch_available():
  raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
 pass
else:
 _lowerCAmelCase							:   int				=				[
     "LILT_PRETRAINED_MODEL_ARCHIVE_LIST",
     "LiltForQuestionAnswering",
     "LiltForSequenceClassification",
     "LiltForTokenClassification",
     "LiltModel",
     "LiltPreTrainedModel",
 ]

if TYPE_CHECKING:
 from .configuration_lilt import LILT_PRETRAINED_CONFIG_ARCHIVE_MAP, LiltConfig

 try:
  if not is_torch_available():
   raise OptionalDependencyNotAvailable()
 except OptionalDependencyNotAvailable:
  pass
 else:
  from .modeling_lilt import (
      LILT_PRETRAINED_MODEL_ARCHIVE_LIST,
      LiltForQuestionAnswering,
      LiltForSequenceClassification,
      LiltForTokenClassification,
      LiltModel,
      LiltPreTrainedModel,
  )

else:
 import sys

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