





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


_a						=   logging.get_logger(__name__)

_a						=   {
    "microsoft/trocr-base-handwritten": (
        "https://huggingface.co/microsoft/trocr-base-handwritten/resolve/main/config.json"
    ),
    # See all TrOCR models at https://huggingface.co/models?filter=trocr
}






class       __A					(					__a				):

			'''simple docstring'''







			lowerCAmelCase_							  =		"trocr"
			lowerCAmelCase_							  =		["past_key_values"]
			lowerCAmelCase_							  =		{
			    "num_attention_heads": "decoder_attention_heads",
			    "hidden_size": "d_model",
			    "num_hidden_layers": "decoder_layers",
			}





			def __init__(					self ,						__lowerCAmelCase=5_0_2_6_5 ,						__lowerCAmelCase=1_0_2_4 ,						__lowerCAmelCase=1_2 ,						__lowerCAmelCase=1_6 ,						__lowerCAmelCase=4_0_9_6 ,						__lowerCAmelCase="gelu" ,						__lowerCAmelCase=5_1_2 ,						__lowerCAmelCase=0.1 ,						__lowerCAmelCase=0.0 ,						__lowerCAmelCase=0.0 ,						__lowerCAmelCase=2 ,						__lowerCAmelCase=0.02 ,						__lowerCAmelCase=0.0 ,						__lowerCAmelCase=True ,						__lowerCAmelCase=False ,						__lowerCAmelCase=True ,						__lowerCAmelCase=True ,						__lowerCAmelCase=1 ,						__lowerCAmelCase=0 ,						__lowerCAmelCase=2 ,						**__lowerCAmelCase ,						):



				'''simple docstring'''







				lowerCamelCase__              =	vocab_size
				lowerCamelCase__              =	d_model
				lowerCamelCase__              =	decoder_layers
				lowerCamelCase__              =	decoder_attention_heads
				lowerCamelCase__              =	decoder_ffn_dim
				lowerCamelCase__              =	activation_function
				lowerCamelCase__              =	max_position_embeddings
				lowerCamelCase__              =	dropout
				lowerCamelCase__              =	attention_dropout
				lowerCamelCase__              =	activation_dropout
				lowerCamelCase__              =	init_std
				lowerCamelCase__              =	decoder_layerdrop
				lowerCamelCase__              =	use_cache
				lowerCamelCase__              =	scale_embedding
				lowerCamelCase__              =	use_learned_position_embeddings
				lowerCamelCase__              =	layernorm_embedding

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










import warnings

from ...utils import logging
from .image_processing_owlvit import OwlViTImageProcessor


_a						=   logging.get_logger(__name__)






class       __A					(					lowerCAmelCase				):

			'''simple docstring'''







			def __init__(					self ,						*__lowerCAmelCase ,						**__lowerCAmelCase							):



				'''simple docstring'''







				warnings.warn(
				    '''The class OwlViTFeatureExtractor is deprecated and will be removed in version 5 of Transformers. Please'''
				    ''' use OwlViTImageProcessor instead.''' ,						__lowerCAmelCase ,						)
				super().__init__(*__lowerCAmelCase ,						**__lowerCAmelCase							)



