code: 
  
  
  """simple docstring"""
  
  
  
  
  
  
  
  def _A		(		lowercase	):
  
  
  
  
  
  
  
      """simple docstring"""
      if len(lowercase	) > 1:
          a					=len(lowercase	) // 2  # Finds the middle of the array
          a					=arr[
              :middle_length
          ]  # Creates an array of the elements in the first half.
          a					=arr[
              middle_length:
          ]  # Creates an array of the elements in the second half.
          a					=len(lowercase	)
          a					=len(lowercase	)
          merge(lowercase	)  # Starts sorting the left.
          merge(lowercase	)  # Starts sorting the right
          a					=0  # Left Counter
          a					=0  # Right Counter
          a					=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]:
                  a					=left_array[left_index]
                  left_index += 1
              else:
                  a					=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
              a					=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
              a					=right_array[right_index]
              right_index += 1
              index += 1
      return arr
  
  
  if __name__ == "__main__":
         import doctest
  
         doctest.testmod()
style_context: 
  
  
  """simple docstring"""
  
  
  
  
  
  
  
  from cva import destroyAllWindows, imread, imshow, waitKey
  def _A		(		lowercase ,					lowercase	):
  
  
  
  
  
  
  
      """simple docstring"""
      a	,   a					=img.shape[0], img.shape[1]
  
      def to_grayscale(lowercase ,					lowercase ,					lowercase	):
          return 0.2126 * red + 0.587 * green + 0.114 * blue
  
      def normalize(lowercase	):
          return min(lowercase ,					2_55	)
  
      for i in range(lowercase	):
          for j in range(lowercase	):
              a					=int(to_grayscale(*img[i][j]	)	)
              a					=[
                  normalize(lowercase	),
                  normalize(greyscale + factor	),
                  normalize(greyscale + 2 * factor	),
              ]
  
      return img
  
  
  if __name__ == "__main__":
         # read original image
         lowerCamelCase_     :     Any    		=						{
             percentage: imread("""image_data/lena.jpg""", 1) for percentage in (1_0, 2_0, 3_0, 4_0)
         }
  
         for percentage, img in images.items():
                make_sepia(img, percentage)
  
         for percentage, img in images.items():
                imshow(F'Original image with sepia (factor: {percentage})', img)
  
         waitKey(0)
         destroyAllWindows()