'''simple docstring'''




from typing import TYPE_CHECKING

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


__UpperCAmelCase					={"configuration_yolos": ["YOLOS_PRETRAINED_CONFIG_ARCHIVE_MAP", "YolosConfig", "YolosOnnxConfig"]}

try:
  if not is_vision_available():
    raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
  pass
else:
  __UpperCAmelCase					=["YolosFeatureExtractor"]
  __UpperCAmelCase					=["YolosImageProcessor"]

try:
  if not is_torch_available():
    raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
  pass
else:
  __UpperCAmelCase					=[
      "YOLOS_PRETRAINED_MODEL_ARCHIVE_LIST",
      "YolosForObjectDetection",
      "YolosModel",
      "YolosPreTrainedModel",
  ]


if TYPE_CHECKING:
  from .configuration_yolos import YOLOS_PRETRAINED_CONFIG_ARCHIVE_MAP, YolosConfig, YolosOnnxConfig

  try:
    if not is_vision_available():
      raise OptionalDependencyNotAvailable()
  except OptionalDependencyNotAvailable:
    pass
  else:
    from .feature_extraction_yolos import YolosFeatureExtractor
    from .image_processing_yolos import YolosImageProcessor

  try:
    if not is_torch_available():
      raise OptionalDependencyNotAvailable()
  except OptionalDependencyNotAvailable:
    pass
  else:
    from .modeling_yolos import (
        YOLOS_PRETRAINED_MODEL_ARCHIVE_LIST,
        YolosForObjectDetection,
        YolosModel,
        YolosPreTrainedModel,
    )


else:
  import sys

  __UpperCAmelCase					=_LazyModule(__name__, globals()["__file__"], _import_structure, module_spec=__spec__)

'''simple docstring'''




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


__UpperCAmelCase					=logging.get_logger(__name__)

__UpperCAmelCase					={
    "Visual-Attention-Network/van-base": (
        "https://huggingface.co/Visual-Attention-Network/van-base/blob/main/config.json"
    ),
}




class        a__ (  UpperCAmelCase__					):
     lowerCamelCase    :	Optional[Any]				="van"






     def __init__(					self						:						Union[str, Any]    ,							a						:						List[Any]=2_24    ,							a						:						Optional[int]=3    ,							a						:						Optional[Any]=[7, 3, 3, 3]    ,							a						:						int=[4, 2, 2, 2]    ,							a						:						Optional[int]=[64, 1_28, 3_20, 5_12]    ,							a						:						str=[3, 3, 12, 3]    ,							a						:						str=[8, 8, 4, 4]    ,							a						:						int="gelu"    ,							a						:						int=0.02    ,							a						:						Optional[int]=1e-6    ,							a						:						List[str]=1e-2    ,							a						:						Union[str, Any]=0.0    ,							a						:						int=0.0    ,							**a						:						Optional[Any]    ,							):





         """simple docstring"""



         super().__init__(**a       )
         __lowerCamelCase            =    image_size
         __lowerCamelCase            =    num_channels
         __lowerCamelCase            =    patch_sizes
         __lowerCamelCase            =    strides
         __lowerCamelCase            =    hidden_sizes
         __lowerCamelCase            =    depths
         __lowerCamelCase            =    mlp_ratios
         __lowerCamelCase            =    hidden_act
         __lowerCamelCase            =    initializer_range
         __lowerCamelCase            =    layer_norm_eps
         __lowerCamelCase            =    layer_scale_init_value
         __lowerCamelCase            =    drop_path_rate
         __lowerCamelCase            =    dropout_rate
