
from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available


__magic_name__           =					{'''configuration_qdqbert''': ['''QDQBERT_PRETRAINED_CONFIG_ARCHIVE_MAP''', '''QDQBertConfig''']}

try:
     if not is_torch_available():
          raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
     pass
else:
     __magic_name__           =					[
         '''QDQBERT_PRETRAINED_MODEL_ARCHIVE_LIST''',
         '''QDQBertForMaskedLM''',
         '''QDQBertForMultipleChoice''',
         '''QDQBertForNextSentencePrediction''',
         '''QDQBertForQuestionAnswering''',
         '''QDQBertForSequenceClassification''',
         '''QDQBertForTokenClassification''',
         '''QDQBertLayer''',
         '''QDQBertLMHeadModel''',
         '''QDQBertModel''',
         '''QDQBertPreTrainedModel''',
         '''load_tf_weights_in_qdqbert''',
     ]


if TYPE_CHECKING:
     from .configuration_qdqbert import QDQBERT_PRETRAINED_CONFIG_ARCHIVE_MAP, QDQBertConfig

     try:
          if not is_torch_available():
               raise OptionalDependencyNotAvailable()
     except OptionalDependencyNotAvailable:
          pass
     else:
          from .modeling_qdqbert import (
              QDQBERT_PRETRAINED_MODEL_ARCHIVE_LIST,
              QDQBertForMaskedLM,
              QDQBertForMultipleChoice,
              QDQBertForNextSentencePrediction,
              QDQBertForQuestionAnswering,
              QDQBertForSequenceClassification,
              QDQBertForTokenClassification,
              QDQBertLayer,
              QDQBertLMHeadModel,
              QDQBertModel,
              QDQBertPreTrainedModel,
              load_tf_weights_in_qdqbert,
          )


else:
     import sys

     __magic_name__           =					_LazyModule(__name__, globals()['''__file__'''], _import_structure, module_spec=__spec__)





def 		SCREAMING_SNAKE_CASE__      ( __lowerCAmelCase							):
    if len(__lowerCAmelCase							) > 1:
        snake_case__  =			len(__lowerCAmelCase							) // 2  # Finds the middle of the array
        snake_case__  =			arr[
            :middle_length
        ]  # Creates an array of the elements in the first half.
        snake_case__  =			arr[
            middle_length:
        ]  # Creates an array of the elements in the second half.
        snake_case__  =			len(__lowerCAmelCase							)
        snake_case__  =			len(__lowerCAmelCase							)
        merge(__lowerCAmelCase							)  # Starts sorting the left.
        merge(__lowerCAmelCase							)  # Starts sorting the right
        snake_case__  =			0  # Left Counter
        snake_case__  =			0  # Right Counter
        snake_case__  =			0  # Position Counter
        while (
            left_index < left_size and right_index < right_size
        ):  # Runs until the lowers size of the left and right are sorted.
            if left_array[left_index] < right_array[right_index]:
                snake_case__  =			left_array[left_index]
                left_index += 1
            else:
                snake_case__  =			right_array[right_index]
                right_index += 1
            index += 1
        while (
            left_index < left_size
        ):  # Adds the left over elements in the left half of the array
            snake_case__  =			left_array[left_index]
            left_index += 1
            index += 1
        while (
            right_index < right_size
        ):  # Adds the left over elements in the right half of the array
            snake_case__  =			right_array[right_index]
            right_index += 1
            index += 1
    return arr


if __name__ == "__main__":
     import doctest

     doctest.testmod()



