





class  lowerCAmelCase							:







  def __init__(      self  :Union[str, Any]   ,							_lowercase  :int ):






     '''simple docstring'''





     lowercase__			       =  n
     lowercase__			       =  [None] * self.n
     lowercase__			       =  0  # index of the first element
     lowercase__			       =  0
     lowercase__			       =  0







  def __len__(      self  :Optional[int] ):






     '''simple docstring'''





     return self.size







  def   UpperCAmelCase					(      self  :List[Any] ):






     '''simple docstring'''





     return self.size == 0







  def   UpperCAmelCase					(      self  :List[Any] ):






     '''simple docstring'''





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







  def   UpperCAmelCase					(      self  :Optional[Any]   ,							_lowercase  :List[Any] ):






     '''simple docstring'''





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

     lowercase__			       =  data
     lowercase__			       =  (self.rear + 1) % self.n
     self.size += 1
     return self







  def   UpperCAmelCase					(      self  :int ):






     '''simple docstring'''





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

     lowercase__			       =  self.array[self.front]
     lowercase__			       =  None
     lowercase__			       =  (self.front + 1) % self.n
     self.size -= 1
     return temp













from typing import TYPE_CHECKING

# rely on isort to merge the imports
from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available


_snake_case           =			{
    """configuration_autoformer""": [
        """AUTOFORMER_PRETRAINED_CONFIG_ARCHIVE_MAP""",
        """AutoformerConfig""",
    ],
}

try:
  if not is_torch_available():
    raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
  pass
else:
  _snake_case           =			[
      """AUTOFORMER_PRETRAINED_MODEL_ARCHIVE_LIST""",
      """AutoformerForPrediction""",
      """AutoformerModel""",
      """AutoformerPreTrainedModel""",
  ]


if TYPE_CHECKING:
  from .configuration_autoformer import (
      AUTOFORMER_PRETRAINED_CONFIG_ARCHIVE_MAP,
      AutoformerConfig,
  )

  try:
    if not is_torch_available():
      raise OptionalDependencyNotAvailable()
  except OptionalDependencyNotAvailable:
    pass
  else:
    from .modeling_autoformer import (
        AUTOFORMER_PRETRAINED_MODEL_ARCHIVE_LIST,
        AutoformerForPrediction,
        AutoformerModel,
        AutoformerPreTrainedModel,
    )

else:
  import sys

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






