



"""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


UpperCAmelCase						:		List[str]			= logging.get_logger(__name__)

UpperCAmelCase						:		Tuple			= {
    "sail/poolformer_s12": "https://huggingface.co/sail/poolformer_s12/resolve/main/config.json",
    # See all PoolFormer models at https://huggingface.co/models?filter=poolformer
}


class    SCREAMING_SNAKE_CASE__ (							__UpperCAmelCase   ):
    lowercase__      =   "poolformer"

    def __init__(				self			:				Union[str, Any] ,  lowerCAmelCase_			:				Dict=3 ,  lowerCAmelCase_			:				List[Any]=1_6 ,  lowerCAmelCase_			:				Dict=1_6 ,  lowerCAmelCase_			:				Optional[int]=3 ,  lowerCAmelCase_			:				int=4.0 ,  lowerCAmelCase_			:				Dict=[2, 2, 6, 2] ,  lowerCAmelCase_			:				Optional[Any]=[6_4, 1_2_8, 3_2_0, 5_1_2] ,  lowerCAmelCase_			:				Optional[Any]=[7, 3, 3, 3] ,  lowerCAmelCase_			:				List[Any]=[4, 2, 2, 2] ,  lowerCAmelCase_			:				Optional[int]=[2, 1, 1, 1] ,  lowerCAmelCase_			:				Any=4 ,  lowerCAmelCase_			:				Optional[int]=0.0 ,  lowerCAmelCase_			:				Optional[int]="gelu" ,  lowerCAmelCase_			:				List[Any]=True ,  lowerCAmelCase_			:				Optional[int]=1E-5 ,  lowerCAmelCase_			:				List[str]=0.02 ,  **lowerCAmelCase_			:				int ,  ):







      """simple docstring"""







      lowercase_								= num_channels
      lowercase_								= patch_size
      lowercase_								= stride
      lowercase_								= padding
      lowercase_								= pool_size
      lowercase_								= hidden_sizes
      lowercase_								= mlp_ratio
      lowercase_								= depths
      lowercase_								= patch_sizes
      lowercase_								= strides
      lowercase_								= num_encoder_blocks
      lowercase_								= drop_path_rate
      lowercase_								= hidden_act
      lowercase_								= use_layer_scale
      lowercase_								= layer_scale_init_value
      lowercase_								= initializer_range
      super().__init__(**lowerCAmelCase_)







class    SCREAMING_SNAKE_CASE__ (							__UpperCAmelCase   ):
    lowercase__      =   version.parse("1.11"   )

    @property
    def 					_UpperCAmelCase	(				self			:				Tuple):







      """simple docstring"""







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




    @property
    def 					_UpperCAmelCase	(				self			:				Union[str, Any]):







      """simple docstring"""







      return 2E-3






"""simple docstring"""
from typing import List

import datasets
from datasets.tasks import AudioClassification

from ..folder_based_builder import folder_based_builder


UpperCAmelCase						:		Union[str, Any]			= datasets.utils.logging.get_logger(__name__)


class    SCREAMING_SNAKE_CASE__ (							folder_based_builder.FolderBasedBuilderConfig   ):
    lowercase__      =   None
    lowercase__      =   None







class    SCREAMING_SNAKE_CASE__ (							folder_based_builder.FolderBasedBuilder   ):
    lowercase__      =   datasets.Audio()
    lowercase__      =   "audio"
    lowercase__      =   AudioFolderConfig
    lowercase__      =   42  # definition at the bottom of the script
    lowercase__      =   AudioClassification(audio_column="audio"      ,  label_column="label"   )







UpperCAmelCase						:		Tuple			= [
    ".aiff",
    ".au",
    ".avr",
    ".caf",
    ".flac",
    ".htk",
    ".svx",
    ".mat4",
    ".mat5",
    ".mpc2k",
    ".ogg",
    ".paf",
    ".pvf",
    ".raw",
    ".rf64",
    ".sd2",
    ".sds",
    ".ircam",
    ".voc",
    ".w64",
    ".wav",
    ".nist",
    ".wavex",
    ".wve",
    ".xi",
    ".mp3",
    ".opus",
]
UpperCAmelCase						:		Any			= AUDIO_EXTENSIONS

