
"""simple docstring"""






from collections import OrderedDict
from typing import Mapping

from packaging import version

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


UpperCAmelCase        =				logging.get_logger(__name__)

UpperCAmelCase        =				{
    """google/vit-base-patch16-224""": """https://huggingface.co/vit-base-patch16-224/resolve/main/config.json""",
    # See all ViT models at https://huggingface.co/models?filter=vit
}



class 			lowercase					( lowercase__		):
			lowercase        =     '''vit'''






			def __init__(self  :	str      ,SCREAMING_SNAKE_CASE_  :	Optional[Any]=768      ,SCREAMING_SNAKE_CASE_  :	str=12      ,SCREAMING_SNAKE_CASE_  :	Optional[Any]=12      ,SCREAMING_SNAKE_CASE_  :	Any=3_072      ,SCREAMING_SNAKE_CASE_  :	List[Any]="gelu"      ,SCREAMING_SNAKE_CASE_  :	Dict=0.0      ,SCREAMING_SNAKE_CASE_  :	int=0.0      ,SCREAMING_SNAKE_CASE_  :	Optional[int]=0.02      ,SCREAMING_SNAKE_CASE_  :	Tuple=1e-12      ,SCREAMING_SNAKE_CASE_  :	Optional[Any]=224      ,SCREAMING_SNAKE_CASE_  :	Tuple=16      ,SCREAMING_SNAKE_CASE_  :	Dict=3      ,SCREAMING_SNAKE_CASE_  :	int=True      ,SCREAMING_SNAKE_CASE_  :	List[Any]=16      ,**SCREAMING_SNAKE_CASE_  :	Dict      ,)       ->	Optional[Any]:





				"""simple docstring"""


				super().__init__(**SCREAMING_SNAKE_CASE_			)

				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												=  image_size
				lowerCAmelCase												=  patch_size
				lowerCAmelCase												=  num_channels
				lowerCAmelCase												=  qkv_bias
				lowerCAmelCase												=  encoder_stride





class 			lowercase					( lowercase__		):
			lowercase        =     version.parse('''1.11'''		)






			@property
			def 					UpperCAmelCase							(self  :	Union[str, Any]			)       ->	Mapping[str, Mapping[int, str]]:





				"""simple docstring"""


				return OrderedDict(
				    [
				        ('''pixel_values''', {0: '''batch''', 1: '''num_channels''', 2: '''height''', 3: '''width'''}),
				    ]			)






			@property
			def 					UpperCAmelCase							(self  :	int			)       ->	float:





				"""simple docstring"""


				return 1e-4




"""simple docstring"""






UpperCAmelCase        =				8.3_144_598




def __magic_name__	(				_lowerCamelCase:		float,					_lowerCamelCase:		float			)					->						float:

	'''simple docstring'''




	if temperature < 0:
		raise Exception('''Temperature cannot be less than 0 K'''			)
	if molar_mass <= 0:
		raise Exception('''Molar mass cannot be less than or equal to 0 kg/mol'''			)
	else:
		return (3 * UNIVERSAL_GAS_CONSTANT * temperature / molar_mass) ** 0.5


if __name__ == "__main__":
					import doctest

					# run doctest
					doctest.testmod()

					# example
					UpperCAmelCase        =				3_0_0
					UpperCAmelCase        =				2_8
					UpperCAmelCase        =				rms_speed_of_molecule(temperature, molar_mass)
					print(f"""Vrms of Nitrogen gas at 300 K is {vrms} m/s""")


