



'''simple docstring'''






from math import asin, atan, cos, radians, sin, sqrt, tan

lowerCAmelCase:   Dict					=		637_8137.0
lowerCAmelCase:   List[Any]					=		635_6752.31_4245
lowerCAmelCase:   str					=		6_3_7_8_1_3_7
def  lowerCamelCase__			(		_A					,     _A					,     _A					,     _A							):
  a		:   Union[str, Any]	  =	(AXIS_A - AXIS_B) / AXIS_A
  a		:   int	  =	atan((1 - flattening) * tan(radians(_A							)							)							)
  a		:   Dict	  =	atan((1 - flattening) * tan(radians(_A							)							)							)
  a		:   Optional[int]	  =	radians(_A							)
  a		:   str	  =	radians(_A							)
  # Equation
  a		:   str	  =	sin((phi_a - phi_a) / 2							)
  a		:   Tuple	  =	sin((lambda_a - lambda_a) / 2							)
  # Square both values
  sin_sq_phi *= sin_sq_phi
  sin_sq_lambda *= sin_sq_lambda
  a		:   Optional[Any]	  =	sqrt(sin_sq_phi + (cos(_A							) * cos(_A							) * sin_sq_lambda)							)
  return 2 * RADIUS * asin(_A							)


if __name__ == "__main__":
     import doctest

     doctest.testmod()




'''simple docstring'''






from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_sentencepiece_available,
    is_tokenizers_available,
    is_torch_available,
)


lowerCAmelCase:   List[Any]					=		{'configuration_reformer': ['REFORMER_PRETRAINED_CONFIG_ARCHIVE_MAP', 'ReformerConfig']}

try:
     if not is_sentencepiece_available():
          raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
     pass
else:
     lowerCAmelCase:   Dict					=		['ReformerTokenizer']

try:
     if not is_tokenizers_available():
          raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
     pass
else:
     lowerCAmelCase:   Tuple					=		['ReformerTokenizerFast']

try:
     if not is_torch_available():
          raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
     pass
else:
     lowerCAmelCase:   List[Any]					=		[
         'REFORMER_PRETRAINED_MODEL_ARCHIVE_LIST',
         'ReformerAttention',
         'ReformerForMaskedLM',
         'ReformerForQuestionAnswering',
         'ReformerForSequenceClassification',
         'ReformerLayer',
         'ReformerModel',
         'ReformerModelWithLMHead',
         'ReformerPreTrainedModel',
     ]


if TYPE_CHECKING:
     from .configuration_reformer import REFORMER_PRETRAINED_CONFIG_ARCHIVE_MAP, ReformerConfig

     try:
          if not is_sentencepiece_available():
               raise OptionalDependencyNotAvailable()
     except OptionalDependencyNotAvailable:
          pass
     else:
          from .tokenization_reformer import ReformerTokenizer

     try:
          if not is_tokenizers_available():
               raise OptionalDependencyNotAvailable()
     except OptionalDependencyNotAvailable:
          pass
     else:
          from .tokenization_reformer_fast import ReformerTokenizerFast

     try:
          if not is_torch_available():
               raise OptionalDependencyNotAvailable()
     except OptionalDependencyNotAvailable:
          pass
     else:
          from .modeling_reformer import (
              REFORMER_PRETRAINED_MODEL_ARCHIVE_LIST,
              ReformerAttention,
              ReformerForMaskedLM,
              ReformerForQuestionAnswering,
              ReformerForSequenceClassification,
              ReformerLayer,
              ReformerModel,
              ReformerModelWithLMHead,
              ReformerPreTrainedModel,
          )

else:
     import sys

     lowerCAmelCase:   str					=		_LazyModule(__name__, globals()['__file__'], _import_structure, module_spec=__spec__)