
from ctypes import c_float, sizeof
from enum import Enum
from typing import TYPE_CHECKING, Optional, Union


if TYPE_CHECKING:
							from .. import AutoFeatureExtractor, AutoProcessor, AutoTokenizer  # tests_ignore
class       A__  (		lowerCAmelCase__							):
							lowerCAmelCase__						:		Any            =				c_float





							@property
							def      a__					(					self    :  List[str]							)		->						int:



											"""simple docstring"""


											return sizeof(self.value							)






def 				__SCREAMING_SNAKE_CASE  (						SCREAMING_SNAKE_CASE			: int       ,				SCREAMING_SNAKE_CASE			: int       ,				SCREAMING_SNAKE_CASE			: int = 0     )	->		int:
				# < 0 is possible if using a dynamic axis
				if dimension <= 0:
								__lowercase								=   fixed_dimension

				dimension -= num_token_to_add
				return dimension




def 				__SCREAMING_SNAKE_CASE  (						SCREAMING_SNAKE_CASE			: int       ,				SCREAMING_SNAKE_CASE			: ParameterFormat     )	->		int:
				return num_parameters * dtype.size




def 				__SCREAMING_SNAKE_CASE  (						SCREAMING_SNAKE_CASE			: str     )	->		Optional[Union["AutoTokenizer", "AutoFeatureExtractor", "AutoProcessor"]]:
				from .. import AutoFeatureExtractor, AutoProcessor, AutoTokenizer  # tests_ignore

				try:
								return AutoProcessor.from_pretrained(SCREAMING_SNAKE_CASE     )
				except (ValueError, OSError, KeyError):
								__lowercase						,   __lowercase								=   None, None
								try:
												__lowercase								=   AutoTokenizer.from_pretrained(SCREAMING_SNAKE_CASE     )
								except (OSError, KeyError):
												pass
								try:
												__lowercase								=   AutoFeatureExtractor.from_pretrained(SCREAMING_SNAKE_CASE     )
								except (OSError, KeyError):
												pass

								if tokenizer is not None and feature_extractor is not None:
												raise ValueError(
												    F"""Couldn't auto-detect preprocessor for {model_name}. Found both a tokenizer and a feature extractor."""     )
								elif tokenizer is None and feature_extractor is None:
												return None
								elif tokenizer is not None:
												return tokenizer
								else:
												return feature_extractor







from ..utils import DummyObject, requires_backends
class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Tuple            =				["tokenizers"]





							def __init__(					self    :  str	,					*_UpperCAmelCase    :  List[str]	,					**_UpperCAmelCase    :  List[str]							)		->						int:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Dict            =				["tokenizers"]





							def __init__(					self    :  str	,					*_UpperCAmelCase    :  Union[str, Any]	,					**_UpperCAmelCase    :  Tuple							)		->						Optional[Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Union[str, Any]            =				["tokenizers"]





							def __init__(					self    :  Union[str, Any]	,					*_UpperCAmelCase    :  Union[str, Any]	,					**_UpperCAmelCase    :  int							)		->						Dict:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[int]            =				["tokenizers"]





							def __init__(					self    :  int	,					*_UpperCAmelCase    :  Dict	,					**_UpperCAmelCase    :  Optional[Any]							)		->						List[str]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		str            =				["tokenizers"]





							def __init__(					self    :  Optional[Any]	,					*_UpperCAmelCase    :  Optional[int]	,					**_UpperCAmelCase    :  Optional[int]							)		->						Optional[int]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[int]            =				["tokenizers"]





							def __init__(					self    :  Any	,					*_UpperCAmelCase    :  Union[str, Any]	,					**_UpperCAmelCase    :  List[str]							)		->						Tuple:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[Any]            =				["tokenizers"]





							def __init__(					self    :  str	,					*_UpperCAmelCase    :  Optional[int]	,					**_UpperCAmelCase    :  Union[str, Any]							)		->						Optional[Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		List[str]            =				["tokenizers"]





							def __init__(					self    :  Optional[int]	,					*_UpperCAmelCase    :  Union[str, Any]	,					**_UpperCAmelCase    :  List[str]							)		->						Optional[Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Any            =				["tokenizers"]





							def __init__(					self    :  Optional[Any]	,					*_UpperCAmelCase    :  Tuple	,					**_UpperCAmelCase    :  Any							)		->						Optional[Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Dict            =				["tokenizers"]





							def __init__(					self    :  List[str]	,					*_UpperCAmelCase    :  Tuple	,					**_UpperCAmelCase    :  List[str]							)		->						List[Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		List[Any]            =				["tokenizers"]





							def __init__(					self    :  Tuple	,					*_UpperCAmelCase    :  Union[str, Any]	,					**_UpperCAmelCase    :  Any							)		->						Any:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Tuple            =				["tokenizers"]





							def __init__(					self    :  int	,					*_UpperCAmelCase    :  int	,					**_UpperCAmelCase    :  Optional[Any]							)		->						List[str]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[int]            =				["tokenizers"]





							def __init__(					self    :  Tuple	,					*_UpperCAmelCase    :  List[Any]	,					**_UpperCAmelCase    :  int							)		->						Tuple:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Tuple            =				["tokenizers"]





							def __init__(					self    :  List[str]	,					*_UpperCAmelCase    :  Any	,					**_UpperCAmelCase    :  str							)		->						int:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		str            =				["tokenizers"]





							def __init__(					self    :  Any	,					*_UpperCAmelCase    :  str	,					**_UpperCAmelCase    :  List[Any]							)		->						List[str]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Dict            =				["tokenizers"]





							def __init__(					self    :  int	,					*_UpperCAmelCase    :  Tuple	,					**_UpperCAmelCase    :  Optional[Any]							)		->						Dict:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Tuple            =				["tokenizers"]





							def __init__(					self    :  Tuple	,					*_UpperCAmelCase    :  str	,					**_UpperCAmelCase    :  List[Any]							)		->						Union[str, Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[Any]            =				["tokenizers"]





							def __init__(					self    :  Dict	,					*_UpperCAmelCase    :  Optional[Any]	,					**_UpperCAmelCase    :  List[Any]							)		->						Optional[Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Dict            =				["tokenizers"]





							def __init__(					self    :  Optional[Any]	,					*_UpperCAmelCase    :  Optional[int]	,					**_UpperCAmelCase    :  List[str]							)		->						Optional[int]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Tuple            =				["tokenizers"]





							def __init__(					self    :  Union[str, Any]	,					*_UpperCAmelCase    :  Optional[int]	,					**_UpperCAmelCase    :  Any							)		->						Tuple:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		List[str]            =				["tokenizers"]





							def __init__(					self    :  Union[str, Any]	,					*_UpperCAmelCase    :  List[Any]	,					**_UpperCAmelCase    :  Any							)		->						Tuple:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		int            =				["tokenizers"]





							def __init__(					self    :  Optional[Any]	,					*_UpperCAmelCase    :  Tuple	,					**_UpperCAmelCase    :  Tuple							)		->						List[str]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		int            =				["tokenizers"]





							def __init__(					self    :  Tuple	,					*_UpperCAmelCase    :  Tuple	,					**_UpperCAmelCase    :  Tuple							)		->						Tuple:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		List[str]            =				["tokenizers"]





							def __init__(					self    :  Tuple	,					*_UpperCAmelCase    :  List[Any]	,					**_UpperCAmelCase    :  Tuple							)		->						List[Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		List[str]            =				["tokenizers"]





							def __init__(					self    :  int	,					*_UpperCAmelCase    :  Optional[Any]	,					**_UpperCAmelCase    :  List[Any]							)		->						List[Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[int]            =				["tokenizers"]





							def __init__(					self    :  Any	,					*_UpperCAmelCase    :  Optional[Any]	,					**_UpperCAmelCase    :  str							)		->						Tuple:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		str            =				["tokenizers"]





							def __init__(					self    :  Optional[int]	,					*_UpperCAmelCase    :  Any	,					**_UpperCAmelCase    :  Union[str, Any]							)		->						int:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Dict            =				["tokenizers"]





							def __init__(					self    :  Union[str, Any]	,					*_UpperCAmelCase    :  Dict	,					**_UpperCAmelCase    :  Any							)		->						Any:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Union[str, Any]            =				["tokenizers"]





							def __init__(					self    :  Any	,					*_UpperCAmelCase    :  Tuple	,					**_UpperCAmelCase    :  Optional[int]							)		->						int:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Union[str, Any]            =				["tokenizers"]





							def __init__(					self    :  Tuple	,					*_UpperCAmelCase    :  Optional[int]	,					**_UpperCAmelCase    :  Tuple							)		->						List[str]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[int]            =				["tokenizers"]





							def __init__(					self    :  Dict	,					*_UpperCAmelCase    :  Optional[Any]	,					**_UpperCAmelCase    :  Optional[int]							)		->						Dict:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Tuple            =				["tokenizers"]





							def __init__(					self    :  Optional[int]	,					*_UpperCAmelCase    :  Dict	,					**_UpperCAmelCase    :  str							)		->						Optional[int]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Tuple            =				["tokenizers"]





							def __init__(					self    :  Optional[int]	,					*_UpperCAmelCase    :  Optional[Any]	,					**_UpperCAmelCase    :  List[Any]							)		->						Optional[Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		int            =				["tokenizers"]





							def __init__(					self    :  Optional[Any]	,					*_UpperCAmelCase    :  Tuple	,					**_UpperCAmelCase    :  Any							)		->						str:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Tuple            =				["tokenizers"]





							def __init__(					self    :  Dict	,					*_UpperCAmelCase    :  List[Any]	,					**_UpperCAmelCase    :  Tuple							)		->						Optional[Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Any            =				["tokenizers"]





							def __init__(					self    :  int	,					*_UpperCAmelCase    :  str	,					**_UpperCAmelCase    :  Any							)		->						Optional[int]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		List[Any]            =				["tokenizers"]





							def __init__(					self    :  Any	,					*_UpperCAmelCase    :  Any	,					**_UpperCAmelCase    :  Tuple							)		->						List[str]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Any            =				["tokenizers"]





							def __init__(					self    :  Union[str, Any]	,					*_UpperCAmelCase    :  Optional[Any]	,					**_UpperCAmelCase    :  Dict							)		->						str:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Union[str, Any]            =				["tokenizers"]





							def __init__(					self    :  List[str]	,					*_UpperCAmelCase    :  List[str]	,					**_UpperCAmelCase    :  List[str]							)		->						Union[str, Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[int]            =				["tokenizers"]





							def __init__(					self    :  Dict	,					*_UpperCAmelCase    :  List[Any]	,					**_UpperCAmelCase    :  List[Any]							)		->						Union[str, Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[Any]            =				["tokenizers"]





							def __init__(					self    :  Optional[int]	,					*_UpperCAmelCase    :  Optional[int]	,					**_UpperCAmelCase    :  str							)		->						Tuple:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Any            =				["tokenizers"]





							def __init__(					self    :  Optional[int]	,					*_UpperCAmelCase    :  str	,					**_UpperCAmelCase    :  Optional[int]							)		->						Optional[int]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		List[str]            =				["tokenizers"]





							def __init__(					self    :  Tuple	,					*_UpperCAmelCase    :  Tuple	,					**_UpperCAmelCase    :  Optional[Any]							)		->						Tuple:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[Any]            =				["tokenizers"]





							def __init__(					self    :  int	,					*_UpperCAmelCase    :  Tuple	,					**_UpperCAmelCase    :  Dict							)		->						Union[str, Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Union[str, Any]            =				["tokenizers"]





							def __init__(					self    :  List[str]	,					*_UpperCAmelCase    :  Optional[Any]	,					**_UpperCAmelCase    :  str							)		->						Union[str, Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[Any]            =				["tokenizers"]





							def __init__(					self    :  Dict	,					*_UpperCAmelCase    :  Tuple	,					**_UpperCAmelCase    :  List[str]							)		->						Any:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		int            =				["tokenizers"]





							def __init__(					self    :  Optional[Any]	,					*_UpperCAmelCase    :  int	,					**_UpperCAmelCase    :  Optional[int]							)		->						Dict:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Tuple            =				["tokenizers"]





							def __init__(					self    :  Optional[int]	,					*_UpperCAmelCase    :  List[str]	,					**_UpperCAmelCase    :  List[Any]							)		->						List[str]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Any            =				["tokenizers"]





							def __init__(					self    :  Optional[int]	,					*_UpperCAmelCase    :  Any	,					**_UpperCAmelCase    :  Tuple							)		->						Tuple:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[int]            =				["tokenizers"]





							def __init__(					self    :  Any	,					*_UpperCAmelCase    :  Optional[int]	,					**_UpperCAmelCase    :  Any							)		->						int:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Tuple            =				["tokenizers"]





							def __init__(					self    :  Tuple	,					*_UpperCAmelCase    :  Any	,					**_UpperCAmelCase    :  Any							)		->						List[str]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		int            =				["tokenizers"]





							def __init__(					self    :  int	,					*_UpperCAmelCase    :  Any	,					**_UpperCAmelCase    :  Any							)		->						str:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		List[Any]            =				["tokenizers"]





							def __init__(					self    :  int	,					*_UpperCAmelCase    :  List[Any]	,					**_UpperCAmelCase    :  Any							)		->						Any:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[int]            =				["tokenizers"]





							def __init__(					self    :  List[Any]	,					*_UpperCAmelCase    :  Any	,					**_UpperCAmelCase    :  Dict							)		->						Optional[Any]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Optional[Any]            =				["tokenizers"]





							def __init__(					self    :  Optional[int]	,					*_UpperCAmelCase    :  List[Any]	,					**_UpperCAmelCase    :  Optional[int]							)		->						List[str]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Any            =				["tokenizers"]





							def __init__(					self    :  Tuple	,					*_UpperCAmelCase    :  List[str]	,					**_UpperCAmelCase    :  Optional[int]							)		->						List[str]:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Any            =				["tokenizers"]





							def __init__(					self    :  List[str]	,					*_UpperCAmelCase    :  Optional[Any]	,					**_UpperCAmelCase    :  str							)		->						int:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)






class       A__  (		metaclass=lowerCAmelCase__							):
							lowerCAmelCase__						:		Dict            =				["tokenizers"]





							def __init__(					self    :  Optional[Any]	,					*_UpperCAmelCase    :  Tuple	,					**_UpperCAmelCase    :  str							)		->						Any:



											"""simple docstring"""


											requires_backends(self	,					['tokenizers']							)





