

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


lowercase_             =     logging.get_logger(__name__)

lowercase_             =     {
    "facebook/data2vec-vision-base-ft": (
        "https://huggingface.co/facebook/data2vec-vision-base-ft/resolve/main/config.json"
    ),
}





class 				__lowerCAmelCase  (      lowercase__							):
  _a		    =						"""data2vec-vision"""




  def __init__(       self							,     lowerCAmelCase=768							,     lowerCAmelCase=12							,     lowerCAmelCase=12							,     lowerCAmelCase=3_072							,     lowerCAmelCase="gelu"							,     lowerCAmelCase=0.0							,     lowerCAmelCase=0.0							,     lowerCAmelCase=0.02							,     lowerCAmelCase=1e-12							,     lowerCAmelCase=224							,     lowerCAmelCase=16							,     lowerCAmelCase=3							,     lowerCAmelCase=False							,     lowerCAmelCase=False							,     lowerCAmelCase=False							,     lowerCAmelCase=False							,     lowerCAmelCase=0.1							,     lowerCAmelCase=0.1							,     lowerCAmelCase=True							,     lowerCAmelCase=[3, 5, 7, 11]							,     lowerCAmelCase=[1, 2, 3, 6]							,     lowerCAmelCase=True							,     lowerCAmelCase=0.4							,     lowerCAmelCase=256							,     lowerCAmelCase=1							,     lowerCAmelCase=False							,     lowerCAmelCase=255							,     **lowerCAmelCase							,     )						->				Tuple:
        '''simple docstring'''






        super().__init__(**__lowerCamelCase      )

        _lowercase			 =hidden_size
        _lowercase			 =num_hidden_layers
        _lowercase			 =num_attention_heads
        _lowercase			 =intermediate_size
        _lowercase			 =hidden_act
        _lowercase			 =hidden_dropout_prob
        _lowercase			 =attention_probs_dropout_prob
        _lowercase			 =initializer_range
        _lowercase			 =layer_norm_eps

        _lowercase			 =image_size
        _lowercase			 =patch_size
        _lowercase			 =num_channels
        _lowercase			 =use_mask_token
        _lowercase			 =use_absolute_position_embeddings
        _lowercase			 =use_relative_position_bias
        _lowercase			 =use_shared_relative_position_bias
        _lowercase			 =layer_scale_init_value
        _lowercase			 =drop_path_rate
        _lowercase			 =use_mean_pooling
        # decode head attributes (semantic segmentation)
        _lowercase			 =out_indices
        _lowercase			 =pool_scales
        # auxiliary head attributes (semantic segmentation)
        _lowercase			 =use_auxiliary_head
        _lowercase			 =auxiliary_loss_weight
        _lowercase			 =auxiliary_channels
        _lowercase			 =auxiliary_num_convs
        _lowercase			 =auxiliary_concat_input
        _lowercase			 =semantic_loss_ignore_index





class 				__lowerCAmelCase  (      lowercase__							):
  _a		    =						version.parse("""1.11"""							)




  @property
  def 						A__  (       self      )						->				Union[str, Any]:
        '''simple docstring'''






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




  @property
  def 						A__  (       self      )						->				List[Any]:
        '''simple docstring'''






        return 1e-4





def   a   (    A__			:     str   ,     A__			:     int  )					->   list[str]:





      """simple docstring"""



      return [sentence[i : i + ngram_size] for i in range(len(A__  ) - ngram_size + 1  )]


if __name__ == "__main__":
  from doctest import testmod

  testmod()


