






def     lowerCamelCase__				(   __lowerCamelCase      :					list		):
  __UpperCAmelCase							:     Dict									=  len(__lowerCamelCase		)

  # Set the gap value to be decreased by a factor of 1.3
  # after each iteration
  __UpperCAmelCase							:     Optional[Any]									=  1.3

  # Continue sorting until the gap is 1
  while gap > 1:
    # Decrease the gap value
    __UpperCAmelCase							:     Tuple									=  int(gap / shrink		)

    # Sort the elements using insertion sort
    for i in range(__lowerCamelCase  ,		len(__lowerCamelCase		)		):
      __UpperCAmelCase							:     List[Any]									=  collection[i]
      __UpperCAmelCase							:     Optional[int]									=  i
      while j >= gap and collection[j - gap] > temp:
        __UpperCAmelCase							:     List[Any]									=  collection[j - gap]
        j -= gap
      __UpperCAmelCase							:     Optional[int]									=  temp

  return collection


if __name__ == "__main__":
       import doctest

       doctest.testmod()










from typing import TYPE_CHECKING

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


a		:	Any      					=			{
    "configuration_deta": ["DETA_PRETRAINED_CONFIG_ARCHIVE_MAP", "DetaConfig"],
}

try:
       if not is_vision_available():
              raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
       pass
else:
       a		:	Optional[int]      					=			["DetaImageProcessor"]

try:
       if not is_torch_available():
              raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
       pass
else:
       a		:	Tuple      					=			[
           "DETA_PRETRAINED_MODEL_ARCHIVE_LIST",
           "DetaForObjectDetection",
           "DetaModel",
           "DetaPreTrainedModel",
       ]


if TYPE_CHECKING:
       from .configuration_deta import DETA_PRETRAINED_CONFIG_ARCHIVE_MAP, DetaConfig

       try:
              if not is_vision_available():
                     raise OptionalDependencyNotAvailable()
       except OptionalDependencyNotAvailable:
              pass
       else:
              from .image_processing_deta import DetaImageProcessor

       try:
              if not is_torch_available():
                     raise OptionalDependencyNotAvailable()
       except OptionalDependencyNotAvailable:
              pass
       else:
              from .modeling_deta import (
                  DETA_PRETRAINED_MODEL_ARCHIVE_LIST,
                  DetaForObjectDetection,
                  DetaModel,
                  DetaPreTrainedModel,
              )

else:
       import sys

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


