





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


UpperCAmelCase_           =	logging.get_logger(__name__)

UpperCAmelCase_           =	{"openai-gpt": "https://huggingface.co/openai-gpt/resolve/main/config.json"}




class 			__UpperCamelCase    (							A__    ):
     __A	:  Any							  =   """openai-gpt"""
     __A	:  Optional[int]							  =   {
         """max_position_embeddings""": """n_positions""",
         """hidden_size""": """n_embd""",
         """num_attention_heads""": """n_head""",
         """num_hidden_layers""": """n_layer""",
     }





     def __init__(     self				,							_UpperCamelCase=40478				,							_UpperCamelCase=512				,							_UpperCamelCase=768				,							_UpperCamelCase=12				,							_UpperCamelCase=12				,							_UpperCamelCase="gelu"				,							_UpperCamelCase=0.1				,							_UpperCamelCase=0.1				,							_UpperCamelCase=0.1				,							_UpperCamelCase=1e-5				,							_UpperCamelCase=0.02				,							_UpperCamelCase="cls_index"				,							_UpperCamelCase=True				,							_UpperCamelCase=None				,							_UpperCamelCase=True				,							_UpperCamelCase=0.1				,							**_UpperCamelCase				,							):
        _UpperCAmelCase           =   vocab_size
        _UpperCAmelCase           =   n_positions
        _UpperCAmelCase           =   n_embd
        _UpperCAmelCase           =   n_layer
        _UpperCAmelCase           =   n_head
        _UpperCAmelCase           =   afn
        _UpperCAmelCase           =   resid_pdrop
        _UpperCAmelCase           =   embd_pdrop
        _UpperCAmelCase           =   attn_pdrop
        _UpperCAmelCase           =   layer_norm_epsilon
        _UpperCAmelCase           =   initializer_range
        _UpperCAmelCase           =   summary_type
        _UpperCAmelCase           =   summary_use_proj
        _UpperCAmelCase           =   summary_activation
        _UpperCAmelCase           =   summary_first_dropout
        _UpperCAmelCase           =   summary_proj_to_labels
        super().__init__(**_UpperCamelCase					)
'''simple docstring'''


from __future__ import annotations

__lowerCAmelCase						:							List[str]    							=						8.988e9  # units = N * m^s * C^-2





def    lowerCAmelCase       (		UpperCamelCase__					: float     ,       UpperCamelCase__					: float     ,       UpperCamelCase__					: float     ,       UpperCamelCase__					: float							):


	"""simple docstring"""
	__UpperCAmelCase      					=      abs(chargea * chargea							)

	if (force, chargea, chargea, distance).count(0							) != 1:
		raise ValueError('''One and only one argument must be 0'''							)
	if distance < 0:
		raise ValueError('''Distance cannot be negative'''							)
	if force == 0:
		__UpperCAmelCase      					=      COULOMBS_CONSTANT * charge_product / (distance**2)
		return {"force": force}
	elif chargea == 0:
		__UpperCAmelCase      					=      abs(UpperCamelCase__							) * (distance**2) / (COULOMBS_CONSTANT * chargea)
		return {"charge1": chargea}
	elif chargea == 0:
		__UpperCAmelCase      					=      abs(UpperCamelCase__							) * (distance**2) / (COULOMBS_CONSTANT * chargea)
		return {"charge2": chargea}
	elif distance == 0:
		__UpperCAmelCase      					=      (COULOMBS_CONSTANT * charge_product / abs(UpperCamelCase__							)) ** 0.5
		return {"distance": distance}
	raise ValueError('''Exactly one argument must be 0'''							)


if __name__ == "__main__":
					import doctest

					doctest.testmod()
