'''simple docstring'''






from collections import OrderedDict
from typing import Mapping

from packaging import version

from ...configuration_utils import PretrainedConfig
from ...onnx import OnnxConfig
from ...utils import logging


SCREAMING_SNAKE_CASE_	   =			logging.get_logger(__name__)

SCREAMING_SNAKE_CASE_	   =			{
    'microsoft/beit-base-patch16-224-pt22k': (
        'https://huggingface.co/microsoft/beit-base-patch16-224-pt22k/resolve/main/config.json'
    ),
    # See all BEiT models at https://huggingface.co/models?filter=beit
}




class    a (       __lowerCAmelCase				):
  __lowerCAmelCase				      =					"""beit"""







  def __init__(							self   ,    snake_case_=8192   ,    snake_case_=768   ,    snake_case_=12   ,    snake_case_=12   ,    snake_case_=3072   ,    snake_case_="gelu"   ,    snake_case_=0.0   ,    snake_case_=0.0   ,    snake_case_=0.0_2   ,    snake_case_=1e-1_2   ,    snake_case_=224   ,    snake_case_=16   ,    snake_case_=3   ,    snake_case_=False   ,    snake_case_=False   ,    snake_case_=False   ,    snake_case_=False   ,    snake_case_=0.1   ,    snake_case_=0.1   ,    snake_case_=True   ,    snake_case_=[3, 5, 7, 11]   ,    snake_case_=[1, 2, 3, 6]   ,    snake_case_=True   ,    snake_case_=0.4   ,    snake_case_=256   ,    snake_case_=1   ,    snake_case_=False   ,    snake_case_=255   ,    **snake_case_   ,    ):

    '''simple docstring'''







    super().__init__(**snake_case_					)

    __UpperCAmelCase:					Dict		= vocab_size
    __UpperCAmelCase:					Optional[Any]		= hidden_size
    __UpperCAmelCase:					Dict		= num_hidden_layers
    __UpperCAmelCase:					Dict		= num_attention_heads
    __UpperCAmelCase:					str		= intermediate_size
    __UpperCAmelCase:					List[str]		= hidden_act
    __UpperCAmelCase:					str		= hidden_dropout_prob
    __UpperCAmelCase:					Optional[Any]		= attention_probs_dropout_prob
    __UpperCAmelCase:					List[str]		= initializer_range
    __UpperCAmelCase:					Optional[int]		= layer_norm_eps

    __UpperCAmelCase:					Any		= image_size
    __UpperCAmelCase:					Any		= patch_size
    __UpperCAmelCase:					Optional[Any]		= num_channels
    __UpperCAmelCase:					List[str]		= use_mask_token
    __UpperCAmelCase:					Dict		= use_absolute_position_embeddings
    __UpperCAmelCase:					int		= use_relative_position_bias
    __UpperCAmelCase:					List[str]		= use_shared_relative_position_bias
    __UpperCAmelCase:					List[Any]		= layer_scale_init_value
    __UpperCAmelCase:					Optional[int]		= drop_path_rate
    __UpperCAmelCase:					Any		= use_mean_pooling
    # decode head attributes (semantic segmentation)
    __UpperCAmelCase:					Optional[int]		= out_indices
    __UpperCAmelCase:					Union[str, Any]		= pool_scales
    # auxiliary head attributes (semantic segmentation)
    __UpperCAmelCase:					Optional[Any]		= use_auxiliary_head
    __UpperCAmelCase:					List[str]		= auxiliary_loss_weight
    __UpperCAmelCase:					List[str]		= auxiliary_channels
    __UpperCAmelCase:					List[Any]		= auxiliary_num_convs
    __UpperCAmelCase:					Optional[Any]		= auxiliary_concat_input
    __UpperCAmelCase:					Union[str, Any]		= semantic_loss_ignore_index




class    a (       __lowerCAmelCase				):
  __lowerCAmelCase				      =					version.parse("""1.11"""				)







  @property
  def    lowercase_  (							self					):

    '''simple docstring'''







    return OrderedDict(
        [
            ("""pixel_values""", {0: """batch""", 1: """num_channels""", 2: """height""", 3: """width"""}),
        ]					)







  @property
  def    lowercase_  (							self					):

    '''simple docstring'''







    return 1e-4
'''simple docstring'''






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


SCREAMING_SNAKE_CASE_	   =			logging.get_logger(__name__)

SCREAMING_SNAKE_CASE_	   =			{
    'facebook/timesformer': 'https://huggingface.co/facebook/timesformer/resolve/main/config.json',
}




class    a (       __lowerCAmelCase				):



  """simple docstring"""
  __lowerCAmelCase				      =					"""timesformer"""







  def __init__(							self   ,    snake_case_=224   ,    snake_case_=16   ,    snake_case_=3   ,    snake_case_=8   ,    snake_case_=768   ,    snake_case_=12   ,    snake_case_=12   ,    snake_case_=3072   ,    snake_case_="gelu"   ,    snake_case_=0.0   ,    snake_case_=0.0   ,    snake_case_=0.0_2   ,    snake_case_=1e-6   ,    snake_case_=True   ,    snake_case_="divided_space_time"   ,    snake_case_=0   ,    **snake_case_   ,    ):

    '''simple docstring'''







    super().__init__(**snake_case_					)

    __UpperCAmelCase:					Tuple		= image_size
    __UpperCAmelCase:					List[Any]		= patch_size
    __UpperCAmelCase:					Optional[Any]		= num_channels
    __UpperCAmelCase:					int		= num_frames

    __UpperCAmelCase:					List[str]		= hidden_size
    __UpperCAmelCase:					List[str]		= num_hidden_layers
    __UpperCAmelCase:					Dict		= num_attention_heads
    __UpperCAmelCase:					List[str]		= intermediate_size
    __UpperCAmelCase:					Union[str, Any]		= hidden_act
    __UpperCAmelCase:					Dict		= hidden_dropout_prob
    __UpperCAmelCase:					Optional[Any]		= attention_probs_dropout_prob
    __UpperCAmelCase:					Union[str, Any]		= initializer_range
    __UpperCAmelCase:					List[Any]		= layer_norm_eps
    __UpperCAmelCase:					int		= qkv_bias

    __UpperCAmelCase:					str		= attention_type
    __UpperCAmelCase:					Tuple		= drop_path_rate