





'''simple docstring'''


def 							UpperCAmelCase_  (						__lowerCamelCase : Any     ,__lowerCamelCase : Optional[Any]			):
   # "extended trapezoidal rule"
   # int(f) = dx/2 * (f1 + 2f2 + ... + fn)
   lowercase_      :Tuple         =			(boundary[1] - boundary[0]) / steps
   lowercase_      :List[str]         =			boundary[0]
   lowercase_      :List[str]         =			boundary[1]
   lowercase_      :Union[str, Any]         =			make_points(__lowerCamelCase     ,__lowerCamelCase     ,__lowerCamelCase			)
   lowercase_      :Any         =			0.0
   y += (h / 2.0) * f(__lowerCamelCase			)
   for i in x_i:
      # print(i)
      y += h * f(__lowerCamelCase			)
   y += (h / 2.0) * f(__lowerCamelCase			)
   return y
def 							UpperCAmelCase_  (						__lowerCamelCase : Optional[int]     ,__lowerCamelCase : List[str]     ,__lowerCamelCase : Optional[int]			):
   lowercase_      :str         =			a + h
   while x < (b - h):
      yield x
      lowercase_      :List[str]         =			x + h
def 							UpperCAmelCase_  (						__lowerCamelCase : str			):  # enter your function here
   lowercase_      :Dict         =			(x - 0) * (x - 0)
   return y
def 							UpperCAmelCase_  (						):
   lowercase_      :Dict         =			0.0  # Lower bound of integration
   lowercase_      :Optional[int]         =			1.0  # Upper bound of integration
   lowercase_      :List[Any]         =			10.0  # define number of steps or resolution
   lowercase_      :Optional[Any]         =			[a, b]  # define boundary of integration
   lowercase_      :Dict         =			method_a(__lowerCamelCase     ,__lowerCamelCase			)
   print(F'y = {y}'			)


if __name__ == "__main__":
 main()









'''simple docstring'''


from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_flax_available,
    is_tf_available,
    is_tokenizers_available,
    is_torch_available,
    is_vision_available,
)


lowerCAmelCase :					int 							={
    '''configuration_clip''': [
        '''CLIP_PRETRAINED_CONFIG_ARCHIVE_MAP''',
        '''CLIPConfig''',
        '''CLIPOnnxConfig''',
        '''CLIPTextConfig''',
        '''CLIPVisionConfig''',
    ],
    '''processing_clip''': ['''CLIPProcessor'''],
    '''tokenization_clip''': ['''CLIPTokenizer'''],
}

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

try:
 if not is_vision_available():
  raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
 pass
else:
 lowerCAmelCase :					str 							=['''CLIPFeatureExtractor''']
 lowerCAmelCase :					Optional[int] 							=['''CLIPImageProcessor''']

try:
 if not is_torch_available():
  raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
 pass
else:
 lowerCAmelCase :					Any 							=[
     '''CLIP_PRETRAINED_MODEL_ARCHIVE_LIST''',
     '''CLIPModel''',
     '''CLIPPreTrainedModel''',
     '''CLIPTextModel''',
     '''CLIPTextModelWithProjection''',
     '''CLIPVisionModel''',
     '''CLIPVisionModelWithProjection''',
 ]

try:
 if not is_tf_available():
  raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
 pass
else:
 lowerCAmelCase :					Union[str, Any] 							=[
     '''TF_CLIP_PRETRAINED_MODEL_ARCHIVE_LIST''',
     '''TFCLIPModel''',
     '''TFCLIPPreTrainedModel''',
     '''TFCLIPTextModel''',
     '''TFCLIPVisionModel''',
 ]

try:
 if not is_flax_available():
  raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
 pass
else:
 lowerCAmelCase :					List[Any] 							=[
     '''FlaxCLIPModel''',
     '''FlaxCLIPPreTrainedModel''',
     '''FlaxCLIPTextModel''',
     '''FlaxCLIPTextPreTrainedModel''',
     '''FlaxCLIPVisionModel''',
     '''FlaxCLIPVisionPreTrainedModel''',
 ]


if TYPE_CHECKING:
 from .configuration_clip import (
     CLIP_PRETRAINED_CONFIG_ARCHIVE_MAP,
     CLIPConfig,
     CLIPOnnxConfig,
     CLIPTextConfig,
     CLIPVisionConfig,
 )
 from .processing_clip import CLIPProcessor
 from .tokenization_clip import CLIPTokenizer

 try:
  if not is_tokenizers_available():
   raise OptionalDependencyNotAvailable()
 except OptionalDependencyNotAvailable:
  pass
 else:
  from .tokenization_clip_fast import CLIPTokenizerFast

 try:
  if not is_vision_available():
   raise OptionalDependencyNotAvailable()
 except OptionalDependencyNotAvailable:
  pass
 else:
  from .feature_extraction_clip import CLIPFeatureExtractor
  from .image_processing_clip import CLIPImageProcessor

 try:
  if not is_torch_available():
   raise OptionalDependencyNotAvailable()
 except OptionalDependencyNotAvailable:
  pass
 else:
  from .modeling_clip import (
      CLIP_PRETRAINED_MODEL_ARCHIVE_LIST,
      CLIPModel,
      CLIPPreTrainedModel,
      CLIPTextModel,
      CLIPTextModelWithProjection,
      CLIPVisionModel,
      CLIPVisionModelWithProjection,
  )

 try:
  if not is_tf_available():
   raise OptionalDependencyNotAvailable()
 except OptionalDependencyNotAvailable:
  pass
 else:
  from .modeling_tf_clip import (
      TF_CLIP_PRETRAINED_MODEL_ARCHIVE_LIST,
      TFCLIPModel,
      TFCLIPPreTrainedModel,
      TFCLIPTextModel,
      TFCLIPVisionModel,
  )

 try:
  if not is_flax_available():
   raise OptionalDependencyNotAvailable()
 except OptionalDependencyNotAvailable:
  pass
 else:
  from .modeling_flax_clip import (
      FlaxCLIPModel,
      FlaxCLIPPreTrainedModel,
      FlaxCLIPTextModel,
      FlaxCLIPTextPreTrainedModel,
      FlaxCLIPVisionModel,
      FlaxCLIPVisionPreTrainedModel,
  )


else:
 import sys

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


