





'''simple docstring'''





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


A_												=     logging.get_logger(__name__)

A_												=     {
    # See all MEGATRON_BERT models at https://huggingface.co/models?filter=bert
}

class SCREAMING_SNAKE_CASE_ (					_UpperCAmelCase   ):





					"""simple docstring"""


					A__				 =    "megatron-bert"





					def __init__( self	,  _lowerCAmelCase=2_9056	,  _lowerCAmelCase=1024	,  _lowerCAmelCase=24	,  _lowerCAmelCase=16	,  _lowerCAmelCase=4096	,  _lowerCAmelCase="gelu"	,  _lowerCAmelCase=0.1	,  _lowerCAmelCase=0.1	,  _lowerCAmelCase=512	,  _lowerCAmelCase=2	,  _lowerCAmelCase=0.02	,  _lowerCAmelCase=1E-12	,  _lowerCAmelCase=0	,  _lowerCAmelCase="absolute"	,  _lowerCAmelCase=True	,  **_lowerCAmelCase	,  ):
										super().__init__(pad_token_id=lowerCamelCase_	,  **lowerCamelCase_	)

										lowerCamelCase__       =       vocab_size
										lowerCamelCase__       =       hidden_size
										lowerCamelCase__       =       num_hidden_layers
										lowerCamelCase__       =       num_attention_heads
										lowerCamelCase__       =       hidden_act
										lowerCamelCase__       =       intermediate_size
										lowerCamelCase__       =       hidden_dropout_prob
										lowerCamelCase__       =       attention_probs_dropout_prob
										lowerCamelCase__       =       max_position_embeddings
										lowerCamelCase__       =       type_vocab_size
										lowerCamelCase__       =       initializer_range
										lowerCamelCase__       =       layer_norm_eps
										lowerCamelCase__       =       position_embedding_type
										lowerCamelCase__       =       use_cache








def    __UpperCamelCase      (    a) ->float:
					return 10 - x * x





def    __UpperCamelCase      (    a,     a) ->float:
					# Bolzano theory in order to find if there is a root between a and b
					if equation(a) * equation(a) >= 0:
										raise ValueError("Wrong space!")

					lowerCamelCase__       =       a
					while (b - a) >= 0.0_1:
										# Find middle point
										lowerCamelCase__       =       (a + b) / 2
										# Check if middle point is root
										if equation(a) == 0.0:
															break
										# Decide the side to repeat the steps
										if equation(a) * equation(a) < 0:
															lowerCamelCase__       =       c
										else:
															lowerCamelCase__       =       c
					return c


if __name__ == "__main__":
						import doctest

						doctest.testmod()

						print(bisection(-2, 5))
						print(bisection(0, 6))

