

"""simple docstring"""




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


__UpperCAmelCase =				logging.get_logger(__name__)

__UpperCAmelCase =				{
    'facebook/s2t-wav2vec2-large-en-de': (
        'https://huggingface.co/facebook/s2t-wav2vec2-large-en-de/resolve/main/config.json'
    ),
    # See all Speech2Text models at https://huggingface.co/models?filter=speech2text2
}







class      __lowercase			(    __lowerCamelCase					):
  snake_case_				       =       """speech_to_text_2"""
  snake_case_				       =       ["""past_key_values"""]
  snake_case_				       =       {"""num_attention_heads""": """decoder_attention_heads""", """hidden_size""": """d_model"""}

  def __init__(  self		:			Optional[Any]					,A		:			Any=10_000					,A		:			Tuple=6					,A		:			Any=2_048					,A		:			int=4					,A		:			Dict=0.0					,A		:			Dict=True					,A		:			int="relu"					,A		:			List[Any]=256					,A		:			Optional[int]=0.1					,A		:			List[str]=0.0					,A		:			Any=0.0					,A		:			str=0.0_2					,A		:			int=2					,A		:			str=True					,A		:			Union[str, Any]=1					,A		:			Optional[int]=0					,A		:			Any=2					,A		:			Optional[Any]=1_024					,**A		:			List[str]					,):






   '''simple docstring'''
   UpperCAmelCase__					:  Tuple					   =					vocab_size
   UpperCAmelCase__					:  List[Any]					   =					d_model
   UpperCAmelCase__					:  List[str]					   =					decoder_ffn_dim
   UpperCAmelCase__					:  Union[str, Any]					   =					decoder_layers
   UpperCAmelCase__					:  Dict					   =					decoder_attention_heads
   UpperCAmelCase__					:  Any					   =					dropout
   UpperCAmelCase__					:  Union[str, Any]					   =					attention_dropout
   UpperCAmelCase__					:  Any					   =					activation_dropout
   UpperCAmelCase__					:  Dict					   =					activation_function
   UpperCAmelCase__					:  int					   =					init_std
   UpperCAmelCase__					:  Optional[Any]					   =					decoder_layerdrop
   UpperCAmelCase__					:  Optional[int]					   =					use_cache
   UpperCAmelCase__					:  int					   =					decoder_layers
   UpperCAmelCase__					:  Optional[int]					   =					scale_embedding  # scale factor will be sqrt(d_model) if True
   UpperCAmelCase__					:  Union[str, Any]					   =					max_target_positions

   super().__init__(
       pad_token_id=A					,bos_token_id=A					,eos_token_id=A					,decoder_start_token_id=A					,**A					,)








"""simple docstring"""




# tests directory-specific settings - this file is run automatically
# by pytest before any tests are run

import sys
import warnings
from os.path import abspath, dirname, join


# allow having multiple repository checkouts and not needing to remember to rerun
# 'pip install -e .[dev]' when switching between checkouts and running tests.
__UpperCAmelCase =				abspath(join(dirname(dirname(__file__)), 'src'))
sys.path.insert(1, git_repo_path)

# silence FutureWarning warnings in tests since often we can't act on them until
# they become normal warnings - i.e. the tests still need to test the current functionality
warnings.simplefilter(action='ignore', category=FutureWarning)
def   lowerCAmelCase						(					__UpperCamelCase      ):
 '''simple docstring'''





 from diffusers.utils.testing_utils import pytest_addoption_shared

 pytest_addoption_shared(__UpperCamelCase      )




def   lowerCAmelCase						(					__UpperCamelCase      ):
 '''simple docstring'''





 from diffusers.utils.testing_utils import pytest_terminal_summary_main

 UpperCAmelCase__					:  Optional[Any]					   =					terminalreporter.config.getoption("""--make-reports"""      )
 if make_reports:
  pytest_terminal_summary_main(__UpperCamelCase							,    id=__UpperCamelCase      )





