

class __UpperCamelCase     :






					'''simple docstring'''



					def __init__(				self				,      lowerCamelCase__						):
						UpperCAmelCase__:	Optional[int]									= n
						UpperCAmelCase__:	Tuple									= [None] * self.n
						UpperCAmelCase__:	str									= 0  # index of the first element
						UpperCAmelCase__:	Union[str, Any]									= 0
						UpperCAmelCase__:	Union[str, Any]									= 0





					def __len__(				self						):
						return self.size





					def    _UpperCAmelCase    (				self						):
						return self.size == 0





					def    _UpperCAmelCase    (				self						):
						return False if self.is_empty() else self.array[self.front]





					def    _UpperCAmelCase    (				self				,      lowerCamelCase__						):
						if self.size >= self.n:
							raise Exception("QUEUE IS FULL"						)

						UpperCAmelCase__:	Optional[Any]									= data
						UpperCAmelCase__:	Tuple									= (self.rear + 1) % self.n
						self.size += 1
						return self





					def    _UpperCAmelCase    (				self						):
						if self.size == 0:
							raise Exception("UNDERFLOW"						)

						UpperCAmelCase__:	List[str]									= self.array[self.front]
						UpperCAmelCase__:	Tuple									= None
						UpperCAmelCase__:	Any									= (self.front + 1) % self.n
						self.size -= 1
						return temp


from typing import TYPE_CHECKING

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


_lowerCAmelCase  :      Tuple			 ={
    """configuration_mobilenet_v2""": [
        """MOBILENET_V2_PRETRAINED_CONFIG_ARCHIVE_MAP""",
        """MobileNetV2Config""",
        """MobileNetV2OnnxConfig""",
    ],
}

try:
					if not is_vision_available():
										raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
					pass
else:
					_lowerCAmelCase  :      Tuple			 =["""MobileNetV2FeatureExtractor"""]
					_lowerCAmelCase  :      Optional[int]			 =["""MobileNetV2ImageProcessor"""]


try:
					if not is_torch_available():
										raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
					pass
else:
					_lowerCAmelCase  :      List[str]			 =[
					    """MOBILENET_V2_PRETRAINED_MODEL_ARCHIVE_LIST""",
					    """MobileNetV2ForImageClassification""",
					    """MobileNetV2ForSemanticSegmentation""",
					    """MobileNetV2Model""",
					    """MobileNetV2PreTrainedModel""",
					    """load_tf_weights_in_mobilenet_v2""",
					]


if TYPE_CHECKING:
					from .configuration_mobilenet_va import (
					    MOBILENET_V2_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_V2_PRETRAINED_MODEL_ARCHIVE_LIST,
										    MobileNetVaForImageClassification,
										    MobileNetVaForSemanticSegmentation,
										    MobileNetVaModel,
										    MobileNetVaPreTrainedModel,
										    load_tf_weights_in_mobilenet_va,
										)


else:
					import sys

					_lowerCAmelCase  :      Any			 =_LazyModule(__name__, globals()["""__file__"""], _import_structure, module_spec=__spec__)