'''simple docstring'''

from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available, is_vision_available


UpperCamelCase__  :						Dict					=      {
    'configuration_chinese_clip': [
        'CHINESE_CLIP_PRETRAINED_CONFIG_ARCHIVE_MAP',
        'ChineseCLIPConfig',
        'ChineseCLIPOnnxConfig',
        'ChineseCLIPTextConfig',
        'ChineseCLIPVisionConfig',
    ],
    'processing_chinese_clip': ['ChineseCLIPProcessor'],
}

try:
  if not is_vision_available():
    raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
  pass
else:
  UpperCamelCase__  :						List[Any]					=      ['ChineseCLIPFeatureExtractor']
  UpperCamelCase__  :						List[str]					=      ['ChineseCLIPImageProcessor']

try:
  if not is_torch_available():
    raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
  pass
else:
  UpperCamelCase__  :						str					=      [
      'CHINESE_CLIP_PRETRAINED_MODEL_ARCHIVE_LIST',
      'ChineseCLIPModel',
      'ChineseCLIPPreTrainedModel',
      'ChineseCLIPTextModel',
      'ChineseCLIPVisionModel',
  ]

if TYPE_CHECKING:
  from .configuration_chinese_clip import (
      CHINESE_CLIP_PRETRAINED_CONFIG_ARCHIVE_MAP,
      ChineseCLIPConfig,
      ChineseCLIPOnnxConfig,
      ChineseCLIPTextConfig,
      ChineseCLIPVisionConfig,
  )
  from .processing_chinese_clip import ChineseCLIPProcessor

  try:
    if not is_vision_available():
      raise OptionalDependencyNotAvailable()
  except OptionalDependencyNotAvailable:
    pass
  else:
    from .feature_extraction_chinese_clip import ChineseCLIPFeatureExtractor, ChineseCLIPImageProcessor

  try:
    if not is_torch_available():
      raise OptionalDependencyNotAvailable()
  except OptionalDependencyNotAvailable:
    pass
  else:
    from .modeling_chinese_clip import (
        CHINESE_CLIP_PRETRAINED_MODEL_ARCHIVE_LIST,
        ChineseCLIPModel,
        ChineseCLIPPreTrainedModel,
        ChineseCLIPTextModel,
        ChineseCLIPVisionModel,
    )

else:
  import sys

  UpperCamelCase__  :						Optional[int]					=      _LazyModule(__name__, globals()['__file__'], _import_structure, module_spec=__spec__)





'''simple docstring'''

from math import factorial, radians







def __UpperCamelCase( _A       :					float	,      _A       :					int = 18	,      _A       :					int = 10     ):
   '''simple docstring'''
   UpperCAmelCase__				:					int 					=	angle_in_degrees - ((angle_in_degrees // 3_6_0.0) * 3_6_0.0)

   # Converting from degrees to radians
   UpperCAmelCase__				:					Dict 					=	radians(_A     )

   UpperCAmelCase__				:					Union[str, Any] 					=	angle_in_radians
   UpperCAmelCase__				:					List[str] 					=	3
   UpperCAmelCase__				:					int 					=	-1

   for _ in range(_A     ):
      result += (b * (angle_in_radians**a)) / factorial(_A     )

      UpperCAmelCase__				:					List[str] 					=	-b  # One positive term and the next will be negative and so on...
      a += 2  # Increased by 2 for every term.

   return round(_A	,      _A     )


if __name__ == "__main__":
  __import__('doctest').testmod()




