



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


UpperCamelCase__ =						logging.get_logger(__name__)

UpperCamelCase__ =						{
    "facebook/timesformer": "https://huggingface.co/facebook/timesformer/resolve/main/config.json",
}
class 			_lowerCAmelCase   ( _UpperCAmelCase			):






			"""simple docstring"""





			lowercase__      :  int      =			"""timesformer"""





			def __init__(				self	:       Optional[int]			,     lowercase	:       Dict=224			,     lowercase	:       Optional[int]=16			,     lowercase	:       Tuple=3			,     lowercase	:       List[str]=8			,     lowercase	:       List[str]=768			,     lowercase	:       Any=12			,     lowercase	:       Optional[Any]=12			,     lowercase	:       Tuple=3_072			,     lowercase	:       Any="gelu"			,     lowercase	:       Any=0.0			,     lowercase	:       Tuple=0.0			,     lowercase	:       Any=0.02			,     lowercase	:       Optional[Any]=1E-6			,     lowercase	:       Union[str, Any]=True			,     lowercase	:       Tuple="divided_space_time"			,     lowercase	:       List[Any]=0			,     **lowercase	:       str			,     )						->					List[str]:
									"""simple docstring"""







									super().__init__(**lowercase   )

									__lowercase					=				image_size
									__lowercase					=				patch_size
									__lowercase					=				num_channels
									__lowercase					=				num_frames

									__lowercase					=				hidden_size
									__lowercase					=				num_hidden_layers
									__lowercase					=				num_attention_heads
									__lowercase					=				intermediate_size
									__lowercase					=				hidden_act
									__lowercase					=				hidden_dropout_prob
									__lowercase					=				attention_probs_dropout_prob
									__lowercase					=				initializer_range
									__lowercase					=				layer_norm_eps
									__lowercase					=				qkv_bias

									__lowercase					=				attention_type
									__lowercase					=				drop_path_rate










UpperCamelCase__ =						{
    "joule": 1.0,
    "kilojoule": 10_00,
    "megajoule": 1_00_00_00,
    "gigajoule": 10_00_00_00_00,
    "wattsecond": 1.0,
    "watthour": 36_00,
    "kilowatthour": 3_60_00_00,
    "newtonmeter": 1.0,
    "calorie_nutr": 41_86.8,
    "kilocalorie_nutr": 4_18_68_00.00,
    "electronvolt": 1.6_0217_6634e-19,
    "britishthermalunit_it": 10_55.0_55_85,
    "footpound": 1.355_818,
}






def  UpperCAmelCase__    (    lowercase__						,       lowercase__						,       lowercase__   ) ->      float:
						if to_type not in ENERGY_CONVERSION or from_type not in ENERGY_CONVERSION:
												__lowercase					=				(
												    F"Incorrect 'from_type' or 'to_type' value: {from_type!r}, {to_type!r}\n"
												    F"Valid values are: {', '.join(lowercase__   )}"
												)
												raise ValueError(lowercase__   )
						return value * ENERGY_CONVERSION[from_type] / ENERGY_CONVERSION[to_type]


if __name__ == "__main__":
			import doctest

			doctest.testmod()





