




"""simple docstring"""
from ....configuration_utils import PretrainedConfig
from ....utils import logging


a_				:    int										=     logging.get_logger(__name__)

# TODO: upload to AWS
a_				:    Union[str, Any]										=     {
    '''yjernite/retribert-base-uncased''': (
        '''https://huggingface.co/yjernite/retribert-base-uncased/resolve/main/config.json'''
    ),
}

class __lowercase(      lowercase__				):




					'''simple docstring'''


					__a						:						List[str]     		= 'retribert'
					def __init__(    self						,	__a=30522						,	__a=768						,	__a=8						,	__a=12						,	__a=3072						,	__a="gelu"						,	__a=0.1						,	__a=0.1						,	__a=512						,	__a=2						,	__a=0.02						,	__a=1E-12						,	__a=True						,	__a=128						,	__a=0						,	**__a						,	):
								super().__init__(pad_token_id=__a						,	**__a     )

								__lowerCamelCase					:	Optional[Any]	       =				vocab_size
								__lowerCamelCase					:	Any	       =				hidden_size
								__lowerCamelCase					:	int	       =				num_hidden_layers
								__lowerCamelCase					:	Optional[int]	       =				num_attention_heads
								__lowerCamelCase					:	int	       =				hidden_act
								__lowerCamelCase					:	str	       =				intermediate_size
								__lowerCamelCase					:	Tuple	       =				hidden_dropout_prob
								__lowerCamelCase					:	Optional[Any]	       =				attention_probs_dropout_prob
								__lowerCamelCase					:	Any	       =				max_position_embeddings
								__lowerCamelCase					:	Dict	       =				type_vocab_size
								__lowerCamelCase					:	str	       =				initializer_range
								__lowerCamelCase					:	List[str]	       =				layer_norm_eps
								__lowerCamelCase					:	Any	       =				share_encoders
								__lowerCamelCase					:	Dict	       =				projection_dim









"""simple docstring"""
import pytest

import datasets


# Import fixture modules as plugins
a_				:    Tuple										=     ['''tests.fixtures.files''', '''tests.fixtures.hub''', '''tests.fixtures.fsspec''']





def 						UpperCAmelCase				(			A__:    List[Any]							,				A__:    Optional[Any]     )  ->     List[str]:
			# Mark tests as "unit" by default if not marked as "integration" (or already marked as "unit")
			for item in items:
						if any(marker in item.keywords for marker in ['integration', 'unit']     ):
									continue
						item.add_marker(pytest.mark.unit     )





def 						UpperCAmelCase				(			A__:    int     )  ->     Optional[int]:
			config.addinivalue_line('markers'							,				'torchaudio_latest: mark test to run with torchaudio>=0.12'     )





@pytest.fixture(autouse=A__     )
def 						UpperCAmelCase				(			A__:    Optional[Any]							,				A__:    List[Any]     )  ->     Any:
			# test_hf_cache_home = tmp_path_factory.mktemp("cache")  # TODO: why a cache dir per test function does not work?
			__lowerCamelCase					:	str	       =				tmp_path_factory.getbasetemp() / 'cache'
			__lowerCamelCase					:	Dict	       =				test_hf_cache_home / 'datasets'
			__lowerCamelCase					:	int	       =				test_hf_cache_home / 'metrics'
			__lowerCamelCase					:	List[str]	       =				test_hf_cache_home / 'modules'
			monkeypatch.setattr('datasets.config.HF_DATASETS_CACHE'							,				str(A__     )     )
			monkeypatch.setattr('datasets.config.HF_METRICS_CACHE'							,				str(A__     )     )
			monkeypatch.setattr('datasets.config.HF_MODULES_CACHE'							,				str(A__     )     )
			__lowerCamelCase					:	List[Any]	       =				test_hf_datasets_cache / 'downloads'
			monkeypatch.setattr('datasets.config.DOWNLOADED_DATASETS_PATH'							,				str(A__     )     )
			__lowerCamelCase					:	Optional[int]	       =				test_hf_datasets_cache / 'downloads' / 'extracted'
			monkeypatch.setattr('datasets.config.EXTRACTED_DATASETS_PATH'							,				str(A__     )     )





@pytest.fixture(autouse=A__							,				scope='session'     )
def 						UpperCAmelCase				(			)  ->     Any:
			datasets.disable_progress_bar()





@pytest.fixture(autouse=A__     )
def 						UpperCAmelCase				(			A__:    Optional[Any]     )  ->     Dict:
			# don't take tests into account when counting downloads
			monkeypatch.setattr('datasets.config.HF_UPDATE_DOWNLOAD_COUNTS'							,				A__     )






@pytest.fixture
def 						UpperCAmelCase				(			A__:    Union[str, Any]     )  ->     Optional[Any]:
			# Required to suppress RemovedIn20Warning when feature(s) are not compatible with SQLAlchemy 2.0
			# To be removed once SQLAlchemy 2.0 supported
			monkeypatch.setattr('sqlalchemy.util.deprecations.SILENCE_UBER_WARNING'							,				A__     )



