



import enum
import inspect
import warnings
from functools import wraps
from typing import Callable, Optional

from .logging import get_logger


UpperCamelCase_      			=  set()
UpperCamelCase_      			=  get_logger(__name__)







def 							A     (						__UpperCAmelCase = None      )			->			Dict:



						'''simple docstring'''






						def decorator(__UpperCAmelCase      ):
												global _emitted_deprecation_warnings

												if inspect.isclass(__UpperCAmelCase      ):
																		UpperCAmelCase_					=	deprecated_class_or_function.__init__
																		UpperCAmelCase_					=	deprecated_class_or_function.__name__
												else:
																		UpperCAmelCase_					=	deprecated_class_or_function
																		UpperCAmelCase_					=	deprecated_function.__name__
																		# Support deprecating __init__ class method: class name instead
																		UpperCAmelCase_					=	name if name != '''__init__''' else deprecated_function.__qualname__.split('''.'''      )[-2]

												UpperCAmelCase_					=	(
												    f"{name} is deprecated and will be removed in the next major version of datasets." + f" {help_message}"
												    if help_message
												    else ''''''
												)

												@wraps(__UpperCAmelCase      )
												def wrapper(*__UpperCAmelCase				,   **__UpperCAmelCase      ):
																		UpperCAmelCase_					=	hash(__UpperCAmelCase      )
																		if func_hash not in _emitted_deprecation_warnings:
																								warnings.warn(__UpperCAmelCase				,   category=__UpperCAmelCase				,   stacklevel=2      )
																								_emitted_deprecation_warnings.add(__UpperCAmelCase      )
																		return deprecated_function(*__UpperCAmelCase				,   **__UpperCAmelCase      )

												UpperCAmelCase_					=	'''deprecated'''

												if inspect.isclass(__UpperCAmelCase      ):
																		UpperCAmelCase_					=	wrapper
																		return deprecated_class_or_function
												else:
																		return wrapper

						return decorator







class 				a_    (						enum.EnumMeta							):

						def __getattribute__(       cls      :Tuple  ,		_lowercase      :Optional[int])						->   Tuple:
												UpperCAmelCase_					=	super().__getattribute__(_lowercase)
												if isinstance(_lowercase  ,		enum.Enum) and obj._on_access:
																		obj._on_access()
												return obj

						def __getitem__(       cls      :List[str]  ,		_lowercase      :List[str])						->   Tuple:
												UpperCAmelCase_					=	super().__getitem__(_lowercase)
												if member._on_access:
																		member._on_access()
												return member




						def __call__(       cls      :Union[str, Any]  ,		_lowercase      :Optional[int]  ,		_lowercase      :List[str]=None  ,		*, _lowercase      :Union[str, Any]=None  ,		_lowercase      :Dict=None  ,		_lowercase      :List[str]=None  ,		_lowercase      :Optional[int]=1)						->   int:
												UpperCAmelCase_					=	super().__call__(_lowercase  ,		_lowercase  ,		module=_lowercase  ,		qualname=_lowercase  ,		type=_lowercase  ,		start=_lowercase)
												if isinstance(_lowercase  ,		enum.Enum) and obj._on_access:
																		obj._on_access()
												return obj







class 				a_    (						enum.Enum   ,					metaclass=_snake_case							):

						def __new__(       cls      :List[Any]  ,		_lowercase      :Union[str, Any])						->   Any:
												UpperCAmelCase_					=	object.__new__(cls)
												UpperCAmelCase_					=	value
												UpperCAmelCase_					=	member.deprecate
												return member

						@property
						def       __a			(       self      :Any)						->   Dict:
												return ""




						def       __a			(       self      :Union[str, Any])						->   List[Any]:
												UpperCAmelCase_					=	f" {self.help_message}" if self.help_message else ''''''
												warnings.warn(
												    f"'{self.__objclass__.__name__}' is deprecated and will be removed in the next major version of datasets."
												    + help_message  ,		_lowercase  ,		stacklevel=3  ,		)










from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available, is_vision_available


UpperCamelCase_      			=  {
    "configuration_mobilenet_v1": [
        "MOBILENET_V1_PRETRAINED_CONFIG_ARCHIVE_MAP",
        "MobileNetV1Config",
        "MobileNetV1OnnxConfig",
    ],
}

try:
							if not is_vision_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							UpperCamelCase_      			=  ["MobileNetV1FeatureExtractor"]
							UpperCamelCase_      			=  ["MobileNetV1ImageProcessor"]

try:
							if not is_torch_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							UpperCamelCase_      			=  [
							    "MOBILENET_V1_PRETRAINED_MODEL_ARCHIVE_LIST",
							    "MobileNetV1ForImageClassification",
							    "MobileNetV1Model",
							    "MobileNetV1PreTrainedModel",
							    "load_tf_weights_in_mobilenet_v1",
							]


if TYPE_CHECKING:
							from .configuration_mobilenet_va import (
							    MOBILENET_V1_PRETRAINED_CONFIG_ARCHIVE_MAP,
							    MobileNetVaConfig,
							    MobileNetVaOnnxConfig,
							)

							try:
														if not is_vision_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .feature_extraction_mobilenet_va import MobileNetVaFeatureExtractor
														from .image_processing_mobilenet_va import MobileNetVaImageProcessor

							try:
														if not is_torch_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .modeling_mobilenet_va import (
														    MOBILENET_V1_PRETRAINED_MODEL_ARCHIVE_LIST,
														    MobileNetVaForImageClassification,
														    MobileNetVaModel,
														    MobileNetVaPreTrainedModel,
														    load_tf_weights_in_mobilenet_va,
														)


else:
							import sys

							UpperCamelCase_      			=  _LazyModule(__name__, globals()["__file__"], _import_structure, module_spec=__spec__)





