






from __future__ import annotations

def        _lowerCamelCase		(  __A      :							List[Any]						,						__A      :							Dict	) ->   Optional[Any]:
    _UpperCAmelCase			: Tuple     					=			0
    _UpperCAmelCase			: Optional[Any]     					=			len(__A	) - 1
    while left <= right:
        _UpperCAmelCase			: Dict     					=			(left + right) // 2
        if left == right:
            if sorted_list[middle] < item:
                _UpperCAmelCase			: Dict     					=			middle + 1
            break
        elif sorted_list[middle] < item:
            _UpperCAmelCase			: List[Any]     					=			middle + 1
        else:
            _UpperCAmelCase			: Optional[Any]     					=			middle - 1
    sorted_list.insert(__A						,						__A	)
    return sorted_list

def        _lowerCamelCase		(  __A      :							Optional[int]						,						__A      :							Optional[int]	) ->   Union[str, Any]:
    _UpperCAmelCase			: str     					=			[]
    while left and right:
        if left[0][0] < right[0][0]:
            result.append(left.pop(0	)	)
        else:
            result.append(right.pop(0	)	)
    return result + left + right

def        _lowerCamelCase		(  __A      :							List[Any]	) ->   Any:
    _UpperCAmelCase			: int     					=			len(__A	)
    if length <= 1:
        return list_ad
    _UpperCAmelCase			: Union[str, Any]     					=			length // 2
    return merge(sortlist_ad(list_ad[:middle]	)						,						sortlist_ad(list_ad[middle:]	)	)

def        _lowerCamelCase		(  __A      :							list[int]	) ->   list[int]:

    if len(__A	) <= 1:
        return collection
    _UpperCAmelCase			: Any     					=			[]
    _UpperCAmelCase			: Any     					=			False
    for i in range(0						,						len(__A	)						,						2	):
        if i == len(__A	) - 1:
            _UpperCAmelCase			: Optional[Any]     					=			True
        else:
            if collection[i] < collection[i + 1]:
                two_paired_list.append([collection[i], collection[i + 1]]	)
            else:
                two_paired_list.append([collection[i + 1], collection[i]]	)
    _UpperCAmelCase			: Optional[int]     					=			sortlist_ad(__A	)
    _UpperCAmelCase			: str     					=			[i[0] for i in sorted_list_ad]
    result.append(sorted_list_ad[-1][1]	)
    if has_last_odd_item:
        _UpperCAmelCase			: str     					=			collection[-1]
        _UpperCAmelCase			: Optional[Any]     					=			binary_search_insertion(__A						,						__A	)
    _UpperCAmelCase			: Tuple     					=			False
    for i in range(len(__A	) - 1	):
        if result[i] == collection[-1] and has_last_odd_item:
            _UpperCAmelCase			: Optional[int]     					=			True
        _UpperCAmelCase			: Optional[int]     					=			sorted_list_ad[i][1]
        # If last_odd_item is inserted before the item's index,
        # you should forward index one more.
        if is_last_odd_item_inserted_before_this_index:
            _UpperCAmelCase			: int     					=			result[: i + 2] + binary_search_insertion(result[i + 2 :]						,						__A	)
        else:
            _UpperCAmelCase			: Any     					=			result[: i + 1] + binary_search_insertion(result[i + 1 :]						,						__A	)

    return result


if __name__ == "__main__":
  SCREAMING_SNAKE_CASE								=  input('Enter numbers separated by a comma:\n').strip()
  SCREAMING_SNAKE_CASE								=  [int(item) for item in user_input.split(',')]
  print(merge_insertion_sort(unsorted))












from collections import OrderedDict
from typing import Mapping

from packaging import version

from ...configuration_utils import PretrainedConfig
from ...onnx import OnnxConfig
from ...utils import logging


SCREAMING_SNAKE_CASE								=  logging.get_logger(__name__)

SCREAMING_SNAKE_CASE								=  {
    'MBZUAI/swiftformer-xs': 'https://huggingface.co/MBZUAI/swiftformer-xs/resolve/main/config.json',
}
class 							A_      (  __lowercase     ):






 '''simple docstring'''




 _SCREAMING_SNAKE_CASE							:     Dict	=   "swiftformer"


 def __init__(		self							,					_A=3							,					_A=[3, 3, 6, 4]							,					_A=[48, 56, 112, 220]							,					_A=4							,					_A=[True, True, True, True]							,					_A="gelu"							,					_A=3							,					_A=2							,					_A=1							,					_A=0.0							,					_A=True							,					_A=1e-5							,					_A=1e-5							,					**_A							,					)	->						List[Any]:

     """simple docstring"""



     super().__init__(**_A)
     _UpperCAmelCase			: Tuple     					=			num_channels
     _UpperCAmelCase			: Optional[int]     					=			depths
     _UpperCAmelCase			: Union[str, Any]     					=			embed_dims
     _UpperCAmelCase			: Dict     					=			mlp_ratio
     _UpperCAmelCase			: Tuple     					=			downsamples
     _UpperCAmelCase			: str     					=			hidden_act
     _UpperCAmelCase			: int     					=			down_patch_size
     _UpperCAmelCase			: Dict     					=			down_stride
     _UpperCAmelCase			: Dict     					=			down_pad
     _UpperCAmelCase			: Tuple     					=			drop_path_rate
     _UpperCAmelCase			: Tuple     					=			use_layer_scale
     _UpperCAmelCase			: int     					=			layer_scale_init_value
     _UpperCAmelCase			: int     					=			batch_norm_eps



class 							A_      (  __lowercase     ):






 '''simple docstring'''




 _SCREAMING_SNAKE_CASE							:     List[Any]	=   version.parse("1.11"     )


 @property
 def 	snake_case__			(		self)	->						Mapping[str, Mapping[int, str]]:

     """simple docstring"""



     return OrderedDict(
         [
             ('''pixel_values''', {0: '''batch''', 1: '''num_channels''', 2: '''height''', 3: '''width'''}),
         ])


 @property
 def 	snake_case__			(		self)	->						float:

     """simple docstring"""



     return 1e-4




