




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


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

__magic_name__     :     Optional[Any]  							=					{
    """ZinengTang/tvlt-base""": """https://huggingface.co/ZinengTang/tvlt-base/blob/main/config.json""",
}





class 						SCREAMING_SNAKE_CASE__		(_a ):
     lowercase_   :			Any   =   "tvlt"
     def __init__(	self  :		str					,	__lowerCamelCase  :		Optional[int]=2_24					,	__lowerCamelCase  :		Union[str, Any]=20_48					,	__lowerCamelCase  :		List[Any]=1_28					,	__lowerCamelCase  :		Dict=[16, 16]					,	__lowerCamelCase  :		Any=[16, 16]					,	__lowerCamelCase  :		List[str]=3					,	__lowerCamelCase  :		List[str]=1					,	__lowerCamelCase  :		Union[str, Any]=8					,	__lowerCamelCase  :		List[str]=7_68					,	__lowerCamelCase  :		List[Any]=12					,	__lowerCamelCase  :		Dict=12					,	__lowerCamelCase  :		Optional[Any]=30_72					,	__lowerCamelCase  :		int="gelu"					,	__lowerCamelCase  :		Optional[int]=0.0					,	__lowerCamelCase  :		str=0.0					,	__lowerCamelCase  :		Tuple=0.02					,	__lowerCamelCase  :		Optional[int]=1e-6					,	__lowerCamelCase  :		Optional[Any]=True					,	__lowerCamelCase  :		List[str]=False					,	__lowerCamelCase  :		Optional[int]=16					,	__lowerCamelCase  :		Union[str, Any]=5_12					,	__lowerCamelCase  :		Optional[Any]=8					,	__lowerCamelCase  :		str=20_48					,	__lowerCamelCase  :		List[str]=0.75					,	__lowerCamelCase  :		List[Any]=0.15					,	__lowerCamelCase  :		Optional[Any]="frame-level"					,	__lowerCamelCase  :		Dict=True					,	__lowerCamelCase  :		List[Any]=True					,	__lowerCamelCase  :		Union[str, Any]="classification"					,	**__lowerCamelCase  :		Optional[int]					,	):



       """simple docstring"""
       super().__init__(**__lowerCamelCase	)

       if audio_mask_type not in ("frame-level", "patch_level"):
         raise ValueError(
             '''audio_mask_type must be one of two acceptable strategies - {\'frame_level\', \'patch-level\') '''
             F"""got {audio_mask_type}"""	)

       lowerCAmelCase__								=			image_size
       lowerCAmelCase__								=			spectrogram_length
       lowerCAmelCase__								=			frequency_length
       lowerCAmelCase__								=			image_patch_size
       lowerCAmelCase__								=			audio_patch_size
       lowerCAmelCase__								=			num_image_channels
       lowerCAmelCase__								=			num_audio_channels
       lowerCAmelCase__								=			num_frames

       lowerCAmelCase__								=			hidden_size
       lowerCAmelCase__								=			num_hidden_layers
       lowerCAmelCase__								=			num_attention_heads
       lowerCAmelCase__								=			intermediate_size
       lowerCAmelCase__								=			hidden_act
       lowerCAmelCase__								=			hidden_dropout_prob
       lowerCAmelCase__								=			attention_probs_dropout_prob
       lowerCAmelCase__								=			initializer_range
       lowerCAmelCase__								=			layer_norm_eps
       lowerCAmelCase__								=			qkv_bias
       lowerCAmelCase__								=			use_mean_pooling

       lowerCAmelCase__								=			decoder_num_attention_heads
       lowerCAmelCase__								=			decoder_hidden_size
       lowerCAmelCase__								=			decoder_num_hidden_layers
       lowerCAmelCase__								=			decoder_intermediate_size
       lowerCAmelCase__								=			pixel_mask_ratio
       lowerCAmelCase__								=			audio_mask_ratio
       lowerCAmelCase__								=			audio_mask_type

       lowerCAmelCase__								=			task_matching
       lowerCAmelCase__								=			task_mae
       lowerCAmelCase__								=			loss_type







__magic_name__     :     dict[str, float]  							=					{
    "kilogram": 1,
    "gram": pow(10, 3),
    "milligram": pow(10, 6),
    "metric-ton": pow(10, -3),
    "long-ton": 0.0009842073,
    "short-ton": 0.0011023122,
    "pound": 2.2046244202,
    "stone": 0.1574731728,
    "ounce": 35.273990723,
    "carrat": 50_00,
    "atomic-mass-unit": 6.022_136_652E26,
}

__magic_name__     :     dict[str, float]  							=					{
    "kilogram": 1,
    "gram": pow(10, -3),
    "milligram": pow(10, -6),
    "metric-ton": pow(10, 3),
    "long-ton": 1016.04608,
    "short-ton": 907.184,
    "pound": 0.453592,
    "stone": 6.35029,
    "ounce": 0.0283495,
    "carrat": 0.0002,
    "atomic-mass-unit": 1.660_540_199E-27,
}
def 		a_       (   __lowerCAmelCase      ,   __lowerCAmelCase      ,   __lowerCAmelCase							):
  if to_type not in KILOGRAM_CHART or from_type not in WEIGHT_TYPE_CHART:
    lowerCAmelCase__								=			(
        F"""Invalid 'from_type' or 'to_type' value: {from_type!r}, {to_type!r}\n"""
        F"""Supported values are: {', '.join(__lowerCAmelCase							)}"""
    )
    raise ValueError(__lowerCAmelCase							)
  return value * KILOGRAM_CHART[to_type] * WEIGHT_TYPE_CHART[from_type]


if __name__ == "__main__":
      import doctest

      doctest.testmod()

